in reply to time in seconds

I have decided to use the epoch time in second and then use it as the seed value in the rand function.

i am therefore doing

my $id = int(rand($epochdate));

Does anybody know what kind of calculation is being done using this rand function and if there is a possibility of two end results being the same (having been generated from the same epoch time or from different time)

costas

Replies are listed 'Best First'.
Re: Re: time in seconds
by Monky Python (Scribe) on Aug 08, 2001 at 20:33 UTC
    This approach does not work because it is unpredictable when a previously assigned number shows up.
    What about using a simple (persistent) counter without using time or rand at all?

    MP