Question: 1. Please answer the following in Python 3 code. Please answer all questions and share code and ouputs. Bus arrival times. Shuttle buses arrive at
1. Please answer the following in Python 3 code. Please answer all questions and share code and ouputs.
Bus arrival times.
Shuttle buses arrive at an airport to fetch passengers with an average interval of 15 minutes. Their actual interarrival times follow an **exponential distribution**.
---
Write a function `simulate_busses(mean, num_busses)` that simulates bus arrival times
- Use a ```random``` module to generate the exponentially distributed bus intervals. - Round your raw data to the nearest tenth of a minute. Realize that rounding is generally scary, and can cause serious problems downstream if not done only when appropriate.
Call your function to generate a list of 50 arrival times with mean 15; capture the result in a variable called `bus_times`. Print your list, and be sure to commit the output.
For example, your list might begin ```[11.2, 34.1, 18.8, 23.5, ...```.
---
Use Python to answer the following questions: 1. What is the shortest waiting time in your list? 2. What is the longest waiting time?
These answers must be programmatically determined and the output that proves you computed them (namely, the values) must be committed.
---
When answering the previous question, did you write a function? Why or why not?
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
