


      RAND(3C)                    (UNIX 5.0)                   RAND(3C)



      NAME
           rand, srand - simple random-number generator

      SYNTAX
           int rand ( )

           void srand (seed)
           unsigned seed;

      DESCRIPTION
           Rand uses a multiplicative congruential random-number
           generator with period 2**32 that returns successive pseudo-
           random numbers in the range 0 to 2**15-1.

           Srand can be called at any time to reset the random-number
           generator to a random starting point. The generator is
           initially seeded with a value of 1.

      NOTES
           The spectral properties of rand leave a great deal to be
           desired.  Drand48 (3C) provides a much better, though more
           elaborate, random-number generator.

      SEE ALSO
           drand48 (3C)






























      Page 1                                         (73 A2 02MTA REV1)



