On the golf course, golfers will see three different types of stakes and/or paint: red stakes and paint for a lateral water hazard or penalty area, yellow stakes and paint for a regular water hazard or penalty area, and white paint or stakes for out of bounds.
Out of bounds is the absolute worse on a golf course. It means you've literally left the property of the golf course with your shot. Your ball is no longer on the golf course when you're out of bounds.
When a golfer hits their ball out of bounds (O.B. for short), there is but one option for continuing, and it's known as the stroke-and-distance penalty. The stroke-and-distance penalty means a golfer takes a one-stroke penalty and has to re-hit the shot from the original position of the shot which went out of bounds. In the case of a tee shot, a golfer can re-tee from the teeing ground in the same or new position and tee off again. In the case of a shot from off the tee, a golfer is to drop as close as possible to the spot from which the original shot was played and go from there.
Basically, going out of bounds leads to one of the most punitive penalties in golf outside of a blatant disregard for the Rules of Golf.
The golfer can lift and clean their ball from out of bounds (assuming they find it and the property owner doesn't make a stink of it) or can put a new golf ball into play to replace the ball which went out of bounds.
Some golf courses, particularly those in the United Kingdom, have out of bounds on the golf-course property. That can sometimes mean the driving range or other practice area, as well clubhouse and member areas. The determination of out of bounds is up to the course and tournament committees. Some, particularly in the United States, choose to treat property boundaries as lateral hazards, allowing players two clublengths of relief from where the ball went off the property.
It's important to check in with individual golf courses and tournament committees to know exactly what's out of bounds and what counts as a lateral hazard.