Question: PLEASE USE BASIC PYTHON LANGUAGE SINCE THIS IS A BEGINNER CLASS PLEASE AND THANK YOU. No conditinals used please Question 3 ( hw 2 _

PLEASE USE BASIC PYTHON LANGUAGE SINCE THIS IS A BEGINNER CLASS PLEASE AND THANK YOU. No conditinals used please
Question 3(hw2_q3.py): Write a program that calculates the estimated time of arrival to a location given a number of random factors.
First, ask the user to enter the start time of the trip as a pair of integers (hours and minutes). Next, determine a random length in kilometers to the destination. The value should be between 46.9 and 287.6. Calculate a random average speed for the trip in kilometers per hour in the range of 24.141kph and 126.3335kph. Both the trip length and average speed should be printed to 3 decimal places.
Given the range and average speed, we can easily calculate the estimated time of arrival. In performing this calculation, be cautious that you represent the time correctly. That is, if the time 60 minutes, you will need to adjust the hour number and the minutes. (A trip that starts at 56 and takes 3:45 is not simply 4:111!) Calculate, store, and print this value as the "base" arrival time.
However, this is New York and New Jersey; we don't go anywhere without traffic. Our trip will include 3 accidents along the way that will impact our arrival time. Calculate (randomly) three time delays (in the range of 5.5 to 43.2 minutes) to account for the accident, and apply the additional delay times (a the floor of the values) to the arrival time. Your program will also print the three delays and the final arrival time at our destination. Finally, print the (new) average speed of the trip accounting for the added time delays.
Example Executions
Enter the start time in hours: 4
Enter the start time in minutes: 56
Length of trip: 48.433 kilometers.
Average speed during trip: 41.857 kilometers per hour.
Base arrival time: 6:5
There were three delays as follows: 34,37, and 24 minutes.
The final arrival time was: 7:40
Final average speed of trip: 5.236 kilometers per hour.
Enter the start time in hours: 12
Enter the start time in minutes: 35
Length of trip: 219.356 kilometers.
Average speed during trip: 83.171 kilometers per hour.
Base arrival time: 15:13
There were three delays as follows: 38,32, and 13 minutes.
The final arrival time was: 16:36
Final average speed of trip: 44.205 kilometers per hour.
 PLEASE USE BASIC PYTHON LANGUAGE SINCE THIS IS A BEGINNER CLASS

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!