You will write three small functions that turn a list of timings into a period.
The idea. A timing that is far from the median is anomalous and is left out. The period is the mean of the others divided by the number of swings. The reaction error is shared between the swings.
Your tasks.
clean, return the timings that are within limit seconds of the median.period, return the mean of the list times divided by swings.percent_error, return the percentage error in the period for a reaction error reaction, a number of swings swings and a period T.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…