I won't repeat the good advice that's already noted above. Another thing to note is try to keep your breathing and HR in check. As others have said, pick your gear for the duration rather than have to change gears during the climb.
Best thing I found when starting out was to find a local climb to get very familiar with - time yourself each climb and use it to help you work out which gears are most efficient for you. It's also good to see whether the "big gear mashing" or "smaller gear spinning" is a better approach for you. Once you're acclimated, then try doing it in progressively tougher gears.