Also true in the animal world. For example, Cicada Magicicada is an insect that spends a prime number of years (13 or 17) living underground as a nymph. This is believed to be a strategy for avoidance of specific predators that evolved multi-year life cycles of their own, by being co-prime to theirs.
Then, all cicadas burrow to the surface, moult, and breed on the same day. This is believed to be an evolved strategy against general bird and wasp predators, which eat their fill but still consume only a small proportion of the mass.
Also, a story from the British Raj in India. Sometime around 1910, a group of Mizoram elders came out of the hills to ask for help. They said the bamboo had just flowered, that this happened only every 50 years, and that last time it happened many people starved to death. The British told them not to believe all the tall tales they were told, and to go away.
Sure enough, the next year millions of extra rats bred because the bamboo flowers result in edible fruit. The year after that, there was no bamboo fruit so the rats ate all the stored corn and rice that was to be planted. And the year after that, many Mizos starved to death.
And then, incredibly, the Assam (Indian) government made precisely the same mistake in 1959, triggering an insurrection that lasted nearly 30 years. And the bamboo is flowering again ... this year.