Here's a timeline to illustrate:
* Sharks: Appeared around 450 million years ago during the Silurian period.
* Dinosaurs: Appeared around 245 million years ago during the Triassic period.
This means sharks were swimming the oceans for over 200 million years before dinosaurs even evolved on land!