Rounding the mean only — why not min and max?

BellaRossiOP

Stage 2 says round the mean to one decimal.

4

Comments 4

Join the discussion

Already have an account? Log in

  1. CharlieHreplies: 2

    Min and max are actual readings, already with their real precision. The mean is computed and can have a long float tail, so rounding it makes the dict clean for every consumer (dashboard, report, alerts).

    5
      1. SophieDev

        And the empty case with None values keeps the same shape. Consumers don't need special handling for missing keys.

        4
    1. AmeliaRuns

      Returning a dict means callers pick what they need. Much better than printing four lines inside.

      5