less flawed random number generator
Posted: Mon Aug 30, 2004 5:53 am
Hello
I have read that the rand() function is quite flawed in the "random" numbers it is generating. I know that I can call srand like so:
before invoking rand(), and in fact as of PHP 4.2.0, there is no need to seed the random number generator as this is now done automatically.
Does anyone know of a better random number generator that I can use for PHP?
Jason
I have read that the rand() function is quite flawed in the "random" numbers it is generating. I know that I can call srand like so:
Code: Select all
srand(make_seed());Does anyone know of a better random number generator that I can use for PHP?
Jason