RANDOM Function (Integer)

Returns a pseudo-random number.


Number := RANDOM(MaxNumber)

Parameters

MaxNumber

Type: Integer

The largest acceptable number. In effect, you are setting a range from one (1) to the number you specify with the MaxNumber parameter.

Type: Integer

A pseudo-random number between one (1) and the number you entered for MaxNumber.

If MaxNumber is negative it acts as a positive.

If MaxNumber is zero this function always returns 1.

A number is always chosen from the same set of numbers. Use RANDOMIZE Function (Integer) to generate a new set of numbers.

Community Additions

ADD
Show: