Imagine someone offers you two plates. One plate holds a single cookie while the other holds three cookies. Which one would you choose? Unless you don't like cookies, you'll pick the plate with three.
Being able to tell more from less is one of the most basic math talents. And it's one that a surprising number of animals have. A robin will pick the piece of wood with more mealworms. A salamander will pick the container with more fruit flies.
Animals will even pick more of something when it means they get less overall. Horses, for example, will go for three tiny apples over two much larger ones.
But animals do not have math class—why would they need to count?
Being able to spot the larger of two groups is useful to animals in lots of ways. It helps them pick the bush with more berries, or run to the larger group of friends. Many fish, for example, join groups for protection. If a predator comes, a fish in a group of 40 is less likely to become lunch than a fish in a group of 10. So if a fish has a choice between two groups, it's better to join the larger one.
Many animals can also do a simple form of counting. keeping track of how many of something there is.
Even animals we don't usually think of as smart can tell the difference between one, two, and three. Fish and honeybees can be trained to get through a maze by choosing turns marked by a certain number of dots—to find the way out, they have to count.
Some animals, such as pigeons, parrots, crows, and rats, can count much higher than three. A pigeon can learn to peck a button exactly 24 times—no more, no less—to get a treat. It can even remember its place and continue counting if interrupted.