Numbers
Function | Description | Meta |
---|---|---|
abs |
Returns the number without its sign. Arguments: Returns:x (number)the number to take the absolute value of y (number)the absolute value of | Wasm |
ceil |
Rounds the number up to the nearest integer. Arguments: Returns:x (number)the number to round y (number)the result of rounding | v0.26.0 Wasm |
x / y |
Divides the first number by the second number. Arguments: Returns:x (number)the dividend y (number)the divisor z (number)the result of | Wasm |
floor |
Rounds the number down to the nearest integer. Arguments: Returns:x (number)the number to round y (number)the result of rounding | v0.26.0 Wasm |
x - y |
Minus subtracts the second number from the first number or computes the difference between two sets. Arguments: Returns:x (any<number, set[any]>)y (any<number, set[any]>)z (any<number, set[any]>)the difference of | Wasm |
x * y |
Multiplies two numbers. Arguments: Returns:x (number)y (number)z (number)the product of | Wasm |
numbers.range |
Returns an array of numbers in the given (inclusive) range. If Arguments: Returns:a (number)the start of the range b (number)the end of the range (inclusive) range (array[number])the range between | v0.22.0 Wasm |
numbers.range_step |
Returns an array of numbers in the given (inclusive) range incremented by a positive step. If "a==b", then "range == [a]"; if "a > b", then "range" is in descending order. If the provided "step" is less then 1, an error will be thrown. If "b" is not in the range of the provided "step", "b" won't be included in the result. Arguments: Returns:a (number)the start of the range b (number)the end of the range (inclusive) step (number)the step between numbers in the range range (array[number])the range between | v0.56.0 SDK-dependent |
x + y |
Plus adds two numbers together. Arguments: Returns:x (number)y (number)z (number)the sum of | Wasm |
rand.intn |
Returns a random integer between Arguments: Returns:str (string)seed string for the random number n (number)upper bound of the random number (exclusive) y (number)random integer in the range | v0.31.0 SDK-dependent |
x % y |
Returns the remainder for of Arguments: Returns:x (number)y (number)z (number)the remainder | Wasm |
round |
Rounds the number to the nearest integer. Arguments: Returns:x (number)the number to round y (number)the result of rounding | Wasm |