# math.roundeven

Available inall subroutines.

Rounds `x`

to nearest, with ties to even values
(also known as *bankers' rounding*).

## Return Value

If `x`

is `math.NAN`

, a NaN will be returned.

If `x`

is integral, ±0, `x`

itself is returned.

If `x`

is `math.POS_INFINITY`

or
`math.NEG_INFINITY`

, an infinity
of the same sign is returned.

Otherwise, the rounded value of `x`

is returned.

## User contributed notes

BETADo you see an error in this page? Do have an interesting use case, example or edge case people should know about? Share your knowledge and help people who are reading this page! (Comments are moderated; for support, please contact Fastly support)