round

round — rounds a real number up or down to the nearest integer.

Syntax

round (number)

		

Arguments

number

A number.

Returns

The nearest integer to the number.

Description

This function rounds its argument to the nearest integer. Values of .5 are rounded up to the next highest integer.

Example

Gamma> round(8.73);
9
Gamma> round(2.21);
2
Gamma> round(5.5);
6
Gamma> round(5.49);
5
Gamma>  
		

See Also

ceil, floor