INT() Function - Convert Decimal to Integer

Syntax

INT(num{,ERR=lineref})

Description

The INT() function converts a numeric argument, removing any fractional digits and truncating all digits to the right of the decimal point.

Parameter

Description

num

Numeric argument to be converted to an integer.

ERR=lineref

Branch to be taken if an error occurs during execution.

Examples

>PRINT INT(5.99)
5
>PRINT INT(.234)
0
>PRINT INT(-6.99)
-6

See Also

Functions - Alphabetical Listing