ID: 12312 Updated by: [EMAIL PROTECTED] Reported By: lramsey at crystalorb dot net Status: Open Bug Type: Feature/Change Request Operating System: Linux 2.4.3 PHP Version: 4.0.6 New Comment:
There's a patch for php-src HEAD at http://bugs.tutorbuddy.com/download.php/php5.array_mt_rand.patch Adds array_mt_rand(). Rewriting the existing functions would be bad for BC if anybody is relying on their current behaviour. J Previous Comments: ------------------------------------------------------------------------ [2003-06-06 17:33:04] [EMAIL PROTECTED] Why not just rewrite array_rand() and shuffle() to instead use mt_srand()? It is "superior" after all... And seeding takes place automatically as of PHP 4.2.0 ------------------------------------------------------------------------ [2003-06-06 14:54:06] [EMAIL PROTECTED] There is no 'array_shuffle()' and shuffle() uses rand too. Having array_mt_rand() is quite good idea. ------------------------------------------------------------------------ [2003-05-31 10:37:15] [EMAIL PROTECTED] Does array_shuffle() solve this? ------------------------------------------------------------------------ [2001-07-22 21:23:20] lramsey at crystalorb dot net As the mt_rand() algorithim creates better random numbers than rand(), would it be possible to include in future releases of the language to include a version of array_rand() that uses mt_rand()? ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=12312&edit=1