Laying eggs led to the dinosaurs' downfall after ruling the Earth for 150 million years, a study suggests.
The direct cause of their extinction 65 million years ago is believed to be a massive asteroid that smashed into the Earth off the coast of Mexico.
But it was the fact dinosaurs hatched out of eggs that ensured they could not survive the catastrophe, the evidence shows.
After the asteroid impact, which altered the Earth's climate, all larger animals on Earth weighing more than around 25 kilograms perished. That included the giant dinosaurs such as Tyrannosaurus rex and the mighty plant-eating Titanosaurs.
While some small dinosaurs took to the air and evolved into birds, mammals took over ecological niches filled by medium-sized animals.
Medium-sized dinosaurs were virtually absent - because of egg laying, say researchers.
Hatching out of eggs, large dinosaurs began their lives much smaller than adults. As they grew, and their body size expanded, they occupied niches that would otherwise have provided a home for medium-sized dinosaur species.
Mammals, which give birth to bigger live babies, were able to diversify into numerous medium-niche species without being crowded out by their own growing offspring.
Study leader Dr Daryl Codron, from the University of Zurich in Switzerland, said: "An overview of the body sizes of all dinosaur species - including those of birds, which are also dinosaurs after all - reveals that few species existed with adults weighing between two and 60 kilograms."
The research, based on computer simulations, is published in the Royal Society journal Biology Letters.
A four-ton mother dinosaur was 2,500 times heavier that its newly hatched baby, said the scientists.
By comparison, a similarly heavy mother elephant weighs only 22 times as much as her newborn calf.
The reason big dinosaurs began life so tiny is that there are physical limits to how big eggs can become.
Larger eggs require thicker shells, through which oxygen must be able to pass.
Co-author Dr Marcus Class, also from the University of Zurich, pointed out that the large size of so many dinosaurs had two important consequences.
"Firstly, this absence of small and medium-sized species was due to the competition among the dinosaurs; in mammals, there was no such gap," he said. "Secondly, in the presence of large dinosaurs and the ubiquitous competition from their young, mammals did not develop large species themselves."
The computer models also showed what happened to small dinosaurs forced to compete both with dinosaur offspring and small mammals.
They were either brought to the brink of extinction or compelled to conquer new niches. Those that evolved the power of flight guaranteed their survival to the present day, as birds.
Join our commenting forum
Join thought-provoking conversations, follow other Independent readers and see their replies