Imagine overhearing the Powerball lottery winning numbers, but you didn’t know when those numbers would be called—just that at some point in the next 10 years or so, they would be. Despite the financial cost of playing those numbers daily for that period, the payoff is big enough to make it worthwhile.

Animals that live in highly variable environments play a similar lottery when it comes to their Darwinian fitness, or how well they are able to pass on their genes. In a new study led by the University of Michigan, scientists found that red squirrels that gambled at the game of reproduction outperformed their counterparts, even if it cost them in the short term.

Natural selection favors female squirrels that have large litters in years when food is abundant because they contribute lots of babies to the gene pool, said Lauren Petrullo, lead author and National Science Foundation postdoctoral research fellow in biopsychology at the University of Michigan.

“We were surprised to find that some females have large litters in years when there won’t be enough food for their babies to survive the winter,” she said. “Because it’s biologically expensive to produce offspring, we wanted to know why these females make what appears to be an error in their reproductive strategy.”

The red squirrels studied live in the Canadian Yukon and experience a “mast year,” or boom in their main food source—seeds from the cones of white spruce trees—once every four to seven years. Squirrels forecast the large mast crop of food before it occurs and increase litter sizes in the months prior, ensuring better future survival for their babies and better fitness for themselves.“There is a constant tug-of-war between the trees and the squirrels at our study site,” Petrullo said, “with each player trying to deceive the other for its own fitness gain.”

Petrullo and Ben Dantzer, U-M associate professor of psychology and of ecology and evolutionary biology, used data collected by the Kluane Red Squirrel Project, a collaborative, 34-year-old field study involving U-M, the University of Colorado, the University of Alberta and the University of Saskatchewan.“Each year, we collect data on how many babies squirrels produce and how many spruce cones the squirrels eat,” Dantzer said.