Mail Archives: djgpp/1998/06/10/22:31:43
From: | Nicolas Blais <eletech AT netrover DOT com>
|
Newsgroups: | comp.os.msdos.djgpp
|
Subject: | Random function gives me the same numbers!
|
Date: | Wed, 10 Jun 1998 21:59:57 -0400
|
Organization: | Elemental Technologies
|
Lines: | 9
|
Message-ID: | <357F3A1C.E19378BD@netrover.com>
|
NNTP-Posting-Host: | 198.168.87.29
|
Mime-Version: | 1.0
|
To: | djgpp AT delorie DOT com
|
DJ-Gateway: | from newsgroup comp.os.msdos.djgpp
|
Hi, the function below seams to always give me the same set of numbers
in R_C everytime I run it, can it be fixed?
srandom(clock()/CLOCKS_PER_SEC);
int R_C = random() / (RAND_MAX / 255 + 1);
Thank you,
Nicolas Blais
- Raw text -