Learning the right climbing technique will help you ascend those hills and mountains faster.
Typically, the most efficient way to climb is in the saddle. This makes the best use of your gluteal muscles and places less anaerobic stress on the body. Spinning a lower gear while seated will also keep your legs fresher for longer.
Get out of the saddle on a climb to add a short burst of speed or just to stretch the legs. It can also be useful to stand on the pedals when the pitch gets a little steeper. Use this technique sparingly, as it can use up more energy than a seated effort.