Navigation

Operators and Keywords

Function List:

C++ API

: round (x)

Return the integer nearest to x.

If x is complex, return round (real (x)) + round (imag (x)) * I. If there are two nearest integers, return the one further away from zero.

round ([-2.7, 2.7])
    ⇒ -3    3

See also: ceil, floor, fix, roundb.

Package: octave