The error message indicates line 5, but there is nothing wrong with that line. To find the
real error, it might be useful to print the value of ratio, which turns out to be 0. The
problem is in line 4, which uses floor division instead of floating-point division.
You should take the time to read error messages carefully, but don’t assume that everything
they say is correct.