no cast required, because `sum` is already a `double`.