Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re^2: Non-Repetitive Random Numbers

by dsheroh (Parson)
on Apr 05, 2013 at 10:04 UTC ( #1027113=note: print w/ replies, xml ) Need Help??


in reply to Re: Non-Repetitive Random Numbers
in thread Non-Repetitive Random Numbers

Please take another look at the documentation you linked to.

The docs for rand state that it "Automatically calls srand unless srand has already been called." It is not necessary to call srand manually and doing so may actually reduce the randomness of the sequence your receive. (If you call srand repeatedly, it will almost certainly do so.)


Comment on Re^2: Non-Repetitive Random Numbers
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1027113]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (8)
As of 2014-12-28 05:03 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (178 votes), past polls