Nightly Job
Start Timer
0:00:00
Every night between 7 pm and midnight, two computing jobs from two different sources are randomly started with each one lasting an hour.
Unfortunately, when the jobs simultaneously run, they cause a failure in some of the company’s other nightly jobs, resulting in downtime for the company that costs $1000.
The CEO, who has enough time today to hear one word, needs a single number representing the annual (365 days) cost of this problem.
Note: Write a function to simulate this problem and output an estimated cost
Bonus - How would you solve this using probability?
Example:
Input:
n = 4
Output:
simulate_overlap(n) -> 0.4
Recommended questions for you
Personalized based on your user activity, skill level, and preferences.
.
.
.
.
.
.
.
.
.
Comments