Counting sheep is a mental exercise used in some cultures as a means of putting oneself to sleep. The practitioner envisions an endless series of identical white sheep jumping over a fence while counting them as they do so. The idea is to occupy the mind with something simple, repetitive, and rhythmic, all of which are known to help humans sleep.