Darwin Help

Back to Index

floor

Function floor


Calling Sequence  floor(x)
Parameters
NameTypeDescription

x a numerical value 
Return Type  integer
Synopsis floor returns the largest integer less than or equal to x. floor(x) = -ceil(-x) for all values of x.
Examples
> floor(-2);
-2
> floor(-1.99999);
-2
> floor(2.000001);
2
See also ceil,   iquo,   mod,   round,   trunc