pub fn floor(x: number) -> numberExpand description
Rounds a number down to the nearest integer.
§Parameters
x: a number.
§Return value
The largest integral value less than or equal to x, as an
integer. Raises an error if the result does not fit in an integer.
§Examples
print(math.floor(4.7)) --> 4
print(math.floor(-4.7)) --> -5
print(math.floor(7)) --> 7