RandRange

Generates a random integer between two specified numbers.

Requests for random integers that are greater than 100,000,000 result in non-random numbers, to prevent overflow during internal computations.

RandRange( number1, number2 [, algorithm ] )

Returns: Number

Argument Description
number1
number, required

smaller number

number2
number, required

bigger number

algorithm
string, optional

The algorithm to use to generate the random number.

  • CFMX_COMPAT (very simple and not very secure algorithm (default)).
  • SHA1PRNG (generates a number using the Sun Java SHA1PRNG algorithm. This algorithm provides greater randomness than the default algorithm)
  • IBMSecureRandom (IBM JVM does not support the SHA1PRNG algorithm)

Examples

There are currently no examples for this function.

See also