You are out walking and see a group of rhinoceroses (which each have two horns and four legs) and triceratopses (which each have three horns and four legs). If you count 31 horns and 48 legs, how many triceratopses are there?
Since each animal has 4 legs, there must be $48 / 4=12$ animals. Each triceratops has 3 horns and each rhinoceros has 2, so if there are $t$ triceratopses and $r$ rhinoceroses we get $t+r=12$ and $3 t+2 r=31$. Subtracting twice the first equation from the second gives $t=7$.