RoundEven(
x
)
Round x to the nearest whole number. If x is halfway between two numbers, choose the
nearest even number (a.k.a. banker's rounding).
Example
=
Block
{
ShowRoundEven
(
-
1.6);
ShowRoundEven
(1.4);
ShowRoundEven
(1.5);
ShowRoundEven
(2.5);
ShowRoundEven
(3.5);
};
The number -1.6 rounds to -2.
The number 1.4 rounds to 1.
The number 1.5 rounds to 2.
The number 2.5 rounds to 2.
The number 3.5 rounds to 4.