A salesman drove from his home to a nearby city at an average speed of 40 mi/. He returned home at an average speed of 50 mi/h. What was his average speed for the entire trip?

I tried this question, and apparently the answer isn't 45 mph. It's something of a trick question. Any help/hints would be much appreciated!

2 answers

Average speed = total distance / total time

time for first trip = d/40
time for return trip = d/50
total time = d/40 + d/50 = 9d/200

total distance = 2d
avg speed = 2d/(9d/200) = 400/9 = 44.444.. mph
Thank you!