Infosys Interview Question

Write program to calculate average speed.