In the United States, there are no national traffic guidelines, but the sequence for traffic lights is usually red, green, yellow and back to red, although some are simply red-green-red.
"Yellow" means halt at the stop line. Drivers may only proceed when the yellow light appears if stopping is likely to cause an accident.
At night or in the early hours of the morning, some junctions and crossroads have flashing traffic lights. A flashing red light indicates "stop" (as at a four-way stop) and a flashing yellow light means "yield" - that is to say, drivers are allowed to proceed if it is safe to do so.
In the UK, the traffic light sequence is red, red and amber (yellow), green, amber and then back to red. Red and amber together is a warning to prepare to move, but drivers must refrain from moving until the light changes to green. Amber means stop at the line. Drivers may proceed only if the amber light appears after they have crossed the stop line or when stopping might cause an accident.
At pedestrian crossings, a flashing amber light follows red, to warn drivers to give way to pedestrians before proceeding. Pedestrians have a legal right of way once they have stepped onto a crossing traffic, and vehicles must stop.
Sources: Living and Working in America, Living and Working in Britain