On a golf course, there are plenty of ways to get into trouble. However, when you find trouble -- be it sand, trees, water or worse -- you also get a clear idea of your options to escape and move on. They come in the form of different colored stakes that tell you the type of hazard you're in and what to do now that you're there.
You'll run into three different types of stakes (or sometimes painted lines) on a golf course: red, yellow and white. Each comes with a different set of options and related penalties, so let's break it down.
What Red, Yellow and White Stakes and Lines Mean
Red stake
A set of red stakes marks the margin of a lateral water hazard. Really, this should be the only kind of water hazard there is, but we digress. A lateral water hazard is water that can come into play with a poor shot, but it runs alongside or adjacent to the intended line of play. These are hazards that, when entered, make little sense to ask a player to drop from behind where the ball entered. It could make the drop onerous or unfair. So, when a player hits their ball in a lateral water hazard, they have some different options. They can hit the ball from the hazard but cannot ground their club in it before hitting the ball. That's usually in water and a bad idea. A player can take a one-stroke penalty and drop within two club lengths of where the ball last crossed the margin (perimeter) of the hazard, no nearer the hole. They can also go to the opposite side of hazard, no nearer the hole, and drop. The player can also drop keeping the ball on the line of the point of the ball's entry in the hazard and the flag and yourself.
Yellow stake
A set of yellow stakes or lines indicates a water hazard. These stakes can also indicate what is considered a water hazard but doesn't always have water in it. A golfer is allowed to play their ball from a water hazard, if possible, without grounding their club in the hazard before the stroke. If the ball isn't playable, then the golfer can take a 1-stroke penalty and use one of two options: return to the original spot of the last shot and drop the ball as near as possible to that spot to hit again, or, keeping a line between themselves, the flag and where the ball crossed the hazard line, they can drop as far back from the hazard as they choose.
White stake
A white stake is the worst of the stakes. It marks out of bounds, either indicating the property line (which can include a fence) or a part of the property where golf isn't to be played. If you find your ball on the wrong side of a white stake, you're taking what's called a stroke-and-distance penalty. That means you have to add 1 stroke to your score and rehit the shot you just played from the same spot. If the shot was from the tee, however, a player can go back to the tee box and pick a new spot to tee up and effectively start the hole over again. White lines can also be used to indicate drop zones and ground under repair, which is a spot on the course from which you shouldn't play and you'll get a free drop no nearer the hole.