The RANDOM function returns a numeric value that is a pseudo-random number from a rectangular distribution. The type of this
function is numeric.
- If argument-1 is specified, it must be zero or a positive integer. It is used as the seed value to generate a sequence of
- If a subsequent reference specifies argument-1, a new sequence of pseudo-random numbers is started.
- If the first reference to this function in the run unit does not specify argument-1, the seed value of zero is used.
- In each case, subsequent references without specifying argument-1 return the next number in the current sequence.
- The returned value is greater than or equal to zero and less than one.
- For a given seed value on a given implementation, the sequence of pseudo-random numbers will always be the same.
- The domain of argument-1 values will yield distinct sequences of pseudo-random numbers. This subset includes the values from
0 through at least 32767.
- Floating-point format is used for numeric non-integer results.