Re: TIB: Random Number Generation Different From The One Before
[Prev][Next][Index][Thread]
Re: TIB: Random Number Generation Different From The One Before
In a message dated 2/25/99 6:31:48 PM Central Standard Time, Parasyte@jps.net
writes:
> >:seq(A,A,1,24\->\L ; initial list
> >:for(A,1,50) ; number of times to shuffle
> >:ipart (24rand)+1\->\B
> >:ipart (24rand)+1\->\C
>
> When will anyone realize that it's not ipart, but int that gets the integer
> part of a number.
> ipart gets the IMAGINARY part. I don't think rand makes imaginary numbers.
> I've had to correct a few basic games that made this same mistake.
If you do want a random integer (on the 86) why not use randint? The syntax
is randint(lower bound,upper bound) and it returns an integer between lower
and upper inclusive. So you type randint(1,24)->C.
PJC