1. Home
  2. Computing & Technology
  3. C / C++ / C#
photo of David Bolton
David's C / C++ / C# Blog

By David Bolton, About.com Guide to C / C++ / C#

Answer to the Average Speed Problem + RSP Results

Sunday February 17, 2008
Such a simple problem but as some of you spotted, it's a trick question. The road is two miles long so at 30 mph it will take two minutes to travel one mile. To get an average speed of 60 mph over two miles would also take two minutes so you have no time left and it is impossible to do the 2nd mile in zero seconds.

A similar but not quite so tricky puzzle is if I travel to a town at 60 mph and then return from there at 40 mph due to slow traffic, what is my average speed for my entire journey? The answer is 48* mph not the 50 that most people guess. The principle is you must not average averages and this type of knowledge isn't usually taught in comp sci classes. So a little bit of maths and/or physics knowledge can come in useful, especially with interview questions!

* Say the distance is 120 miles. It takes two hours to get there and three hours to return. 240 /5 hours = 48 mph average speed.

RSP Results have been posted

Comments

No comments yet. Leave a Comment

Leave a Comment

Line and paragraph breaks are automatic. Some HTML allowed: <a href="" title="">, <b>, <i>, <strike>

Explore C / C++ / C#
About.com Special Features

Stay connected and entertained with reviews on tips on the latest HDTVs, cellphones and more. More >

Easy ways to connect two computers for networking purposes. More >

  1. Home
  2. Computing & Technology
  3. C / C++ / C#

©2009 About.com, a part of The New York Times Company.

All rights reserved.