Math

interface

interface Math

Methods

sumPrecise

sumPrecise(values: Iterable<number>): number

Returns the sum of the given values using a more precise algorithm than a naive +-based reduction, avoiding the floating-point rounding errors that accumulate when summing many numbers.

MDN Reference