Derailleur-type gears are used on 10 and 12-speed bikes; hub-and-sprocket type gears are used on most 3-speed and some 4- and 5-speed bikes. The derailleur mechanism shifts the drive chain from one gear to mother to vary forward speeds. To prevent derailleurs from slipping out of adjustment, never lay your bike down on its right side, shift only while pedaling, and never backpedal. If the chain slips off the freewheel cogs while you are riding, or refuses to go onto the largest or smallest cogs, the rear derailleur needs adjusting.
Hang your bicycle (or have someone hold it up) so that the rear wheel is off the ground. Look for the adjustment screws on the rear derailleur. They are probably marked H and L for High (the smallest gear on the freewheel) and Low (the largest). These screws keep the derailleur from traveling too far to the left or right. Turn the screws a little at a time until the chain centers perfectly on the appropriate cog when you shift and pedal by hand. Adjust the front derailleur in the same way.
For slipping or binding of hub and sprocket gears, adjust the sleeve nut on the end of the toggle chain. Shift the handlebar lever to first gear, then turn the sleeve nut while looking at the inspection hole in the tunnel nut. When the rivet at the end of the toggle chain is in the center of the hole, shift to second gear, give the sleeve nut another half turn, and shift back to first gear. The cable should be taut, with the lever just managing the shift. Turn the locknut finger tight against the sleeve nut.