Tinderbox v9 Icon

Number.floor()


Operator Type: 

Operator Scope of Action: 

Operator Purpose: 

Operator First Added: 

Operator Last Altered: 

 Function  [other Function type actions]

 Item  [operators of similar scope]

 Mathematical  [other Mathematical operators]

 9.5.2

 As at baseline


Syntax note: Operators without any defined mandatory arguments may omit their empty closing parentheses


Number.floor()

From v9.5.2, Number.floor() rounds the source number value of sourceNum down to previous whole integer. This is a dot-operator

See also Number.ceil() and Number.round().

If $MyNumber is 3.9 then:

$MyNumber = $MyNumber.floor(); 

sets $MyNumber to 3. Note unlike normal rounding the value is set downwards to the next integer (i.e. whole number).