TypstDocumentation

floor

Round a number down to the nearest integer.

If the number is already an integer, it is returned unchanged.

Example

#assert(calc.floor(3.14) == 3)
#assert(calc.floor(3) == 3)
#calc.floor(500.1)
Preview

Parameters
Question mark

floor()

value
integerfloatRequiredPositional
Question mark

The number to round down.