Question: Chapter 2 Vehicle Routing An intercampus shuttle can take one of several routes. For each run, a dispatcher checks what the current traffic conditions are

Chapter 2
Vehicle Routing
An intercampus shuttle can take one of several routes. For each run, a dispatcher checks what the current traffic conditions are to find out the average speed on each route and determine which route the shuttle driver should take.
a) Write a program that:
prompts for two inputs: distance in miles, and speed in miles per hour
calculates the time the route should take (in hours), and displays this result
b) In addition to displaying the time in hours, enhance your program to display the result in minutes, rounding the result to one decimal.
c) Assume current traffic conditions are those found in the table follows. Run your program three times using the data below to determine the fastest route.
\table[[Route type,\table[[Distance],[(miles)]],\table[[Current speed],[(miles/hour)]]],[local,30,30],[parkway,35,40],[highway,48,55]]
 Chapter 2 Vehicle Routing An intercampus shuttle can take one of

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!