home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 5 / 05.iso / a / a079 / 1.img / FPDG.LZH / VOL2NUM0 / FLIPCOIN / FLIPCOIN.ART < prev    next >
Encoding:
Text File  |  1993-02-01  |  405 b   |  2 lines

  1. The FLIPCOIN.PRG illustrates the use of the RAND() function as presented in Chapter 5. RAND() is a pseudorandom number generator that generates a number between 0.0 and 1.0. In FLIPCOIN.PRG, if RAND() returns a number less than 0.5, a circle with "TAILS" in it displays. Otherwise, it displays a circle with "HEADS" in it. It counts and reports the number of heads and tails as you repeat its operation.
  2.