Horns, Frills and Armour

Why do dinosaurs split into two big groups?