An unusual prehistoric fish with fins near its butt has helped to solve the mystery over why most animals, including humans, have paired limbs.