delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/08/21/00:16:16

Date: Wed, 20 Aug 1997 23:16:04 -0500 (CDT)
From: Andrew Deren <aderen AT eecs DOT uic DOT edu>
To: Zampelli Stéphane <xyy AT infonie DOT be>
cc: djgpp AT delorie DOT com
Subject: Re: Random numbers...
In-Reply-To: <01bcaa71$4c08c200$0d5e4ec2@xyy>
Message-ID: <Pine.SUN.3.95.970820231459.24595C-100000@bert.eecs.uic.edu>
MIME-Version: 1.0

DId you try resetting srand with time?

Try srand((int) time (NULL));

On 16 Aug 1997, Zampelli Stéphane wrote:

> 
> Hi!
> 
> 
> I still can't obtain truly random numbers with the srand(), random(), and
> rand() functions, because, whatever the seed number i put in srand(), it is
> _always the same results.
> 
> What can i do about it ?
> 
> 	A+. Xyy.
> 
> 
> 


                        ,,,
                       (0 0)
   +-------------oOO----(_)-------------------+
   |                Andrew Deren              |  
   |             aderen AT eecs DOT uic DOT edu          |
   | www.eecs.uic.edu/~aderen/ader/main.html  |
   +-------------------------oOO--------------+
                       || ||
                      ooO Ooo
 


- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019