A boy, a girl, and a dog simultaneously begin movement from one point. Boy and girl are heading in one direction, boy - with speed 5 km/h, girl - 4 km/h. The dog runs from boy to girl and back with speed 10 km/h. Given that it takes no time for the dog to change direction, how much will the dog travel in 1 hour?