You will write three small functions about an earthquake alert.
The idea. The S wave moves at 3.5 km/s. An alert is sent a few seconds after the earthquake starts. A city gets a warning only if the S wave arrives after the alert is sent.
Your tasks.
s_arrival, return the time in seconds that the S wave needs to travel distance km.warning, return the warning time in seconds. If the shaking comes first, return 0.blind_zone, return the radius in km of the area that gets no warning, when the alert is sent delay seconds after the start.Run your code once to unlock the worked solution.
Have you tried it?
Do the tasks in the editor first, and run the checker after each one. Its hints help when a check fails. When you are ready, compare your code with this solution.
Log in to join the discussion.
Loading…