But which one should you use? Use the one that allows you to pedal comfortably in that 80 to 90 rpm cadence range. Start off easier, in the small chainring (the one by your pedal) and one of the middle cogs near your back wheel. Shift (with your right shifter) to a harder cog if that's too easy. If you keep moving the right shifter and it's still too easy, shift to the big chainring. What "number" gear you're in doesn't matter. What matters is being able to turn your pedals at a good cadence while still being relatively comfortable.
Here are a couple of scenarios: If you are riding up a fairly steep hill you'll probably ride in the small chainring and one of the easiest cogs. If you are on a slight downhill you probably will be in the big chainring and one of the harder cogs. Experiment to see what works for you.
More: Sitting Vs. Standing When Cycling Uphill
Shifting
Finally, shifting gears smoothly takes practice and anticipation. You can't shift bike gears unless you're pedaling. If you're coasting along, not moving the pedals, and you move the shifter, nothing will happen. You must be pedaling forward before the gear will change.
But there's a little trick with this. In order for the bike to shift smoothly you need to be pedaling softly as you change gears. If you're pushing down hard on your pedals as you shift, the gears will probably make a horrible griding sound and may not actually change. Ease up on your force for a brief second or two (don't stop pedaling though) and it will do what you want it to do.
More: 3 Shifting Tips for Rookie Cyclists
Anticipating Gear Changes
When approaching a hill, you should shift into the small chainring slightly ahead of time, before you start to slow down too much. As you go up the hill, if that isn't easy enough, you can shift to an easier cog. Try to anticipate this so you can shift before it gets too difficult. Once the hill begins to flatten out or you reach the top, you will shift to a harder cog and, if need be, to the big chainring. You want to anticipate this as well, so that your legs aren't spinning around without purpose.
Practice! Prop your bike's rear wheel up off the ground, or ask someone to hold it up for you. Turn the pedals with your hand and move the shifters so that you can actually watch as the bike gears change. Then take your bike to a parking lot or a hard grass or dirt field and practice gear changes. This way you won't have to worry about cars, obstacles or other riders while getting used to your gears. You will gain confidence and be more comfortable after a little practice.
More: A Breakdown of the Cycling Pedal Stroke
Search for your next triathlon.