[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
RND Random Number
y = RND [(n)]
Generates a single-precision pseudo-random number in the range of 0 to
1.
n A numeric expression.
-------------------------------------------------------------------------
Notes: If n is omitted or is positive, RND returns the next
random number in the current sequence.
If n is 0, RND returns the last (most recent) random
number in the current sequence.
If n is negative, BASIC uses n to reseed the random number
function. The first number in the reseeded random number
series is returned.
To produce random integers in the range 1 to Max, use the
following formula:
newRandom% = INT (RND * Max) + 1
See Also:
RANDOMIZE
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson