Random Function
Returns a random integer between the specified minimum and maximum values.
Syntax
Random(minValue, maxValue)
Returns a random integer between the specified minimum and maximum values.
Arguments
minValue
Integer - The minimum value for the random number, inclusive. A decimal value will be truncated to an integer.
maxValue
Integer - The maximum value for the random number, exclusive. A decimal value will be truncated to an integer.
Remarks
-
This function will not trigger re-firing of rules though changes to supplied arguments may.
-
Since this function returns an integer, you may divide by a power of ten to produce a decimal value. For example, "Random(0, 10000) / 1000" gives a random number between 0.000 and 9.999.
Example:
Random(1, 10); // returns 3
Example:
Random(1, 10); // returns 7
Example:
Random(2, 1); // returns 1
Example:
Random(1, 2); // returns 1
Example:
Random(1, 1); // returns 1