B4Coder

🏏 Cricket Scoreboard · Mission 5 of 8

⏱️ Overs

An over is 6 balls. The scoreboard shows overs like 2.3: two whole overs and three balls. Work it out from the balls the batters have faced.

Your mission

  1. balls = every batter's balls added up (in the totals loop).
  2. overs = floor(balls / 6) + "." + balls % 6: whole overs, a dot, then the balls into the next.
  3. Keep the total, wickets and the rules from before.

Getting the mission ready…