Skip to content

Integer

The integer data type is used to represent whole numbers, and is stored as a 32-bit signed integer.

Examples

More on the built-in functions can be found in the Built-in Function section

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
var int = 123

# Operations
var int = int + 3  # 126
var int = int - 3  # 123
var int = int * 2  # 246
var int = int / 6  # 41
var int = int ^ 2  # 1681
var int = -int  # -1681

# Check if type is an integer
isInteger(int)  # 1

# Check if not 0 (falsy or truthy)
isTrue(int)  # 0