Everything

lround functions and llround functions [V2.01.00 or later]


[Syntax]

long int lround(double x)

long int lroundf(float x)

long int lroundl(long double x)

long long int llround(double x)

long long int llroundf(float x)

long long int llroundl(long double x)

[Description]

These functions round x to the nearest integer value. If x is just in the middle, the value in the direction farther away from 0 is selected, regardless of the current rounding direction.

 

[Special case]

Condition

Return value

Exception

x==NaN

0

EDOM

x==±∞

0

EDOM