> I seriously doubt that - there is nothing in the ECMAScript > specification that says how Math.random works. Most modern computers > can calculate quite a few random numbers per millisecond - a 2GHz > Core2Duo does between 10 and 50 in Firefox, up to 170 in Safari. A > simple test shows no duplicates in all the numbers generated in a > single millisecond. Do you have any references indicating a problem? > > The ECMAScript spec says: > > "15.8.2.14 random ( ) > "Returns a number value with positive sign, greater than or > equal to 0 but lessthan 1, chosen randomly or pseudo > randomly with approximately uniform distribution over that > range, using an implementation-dependent algorithm or > strategy. This function takes no arguments." > > I don't see anywhere there that says "must use the system clock to > seed the algorithm". >
In fact I already get this issue in Java so I thought it could be possible in JavaScript. -- Jean-Philippe Encausse - R&D Jalios SA Jp [at] encausse.net - http://www.encausse.com - http://www.jalias.com GTalk: jp.encausse [at] gmail.com - SMS: sms [at] jp.encausse.net Mob: +33682125699 - Job: +33139239283 - Tel: +33139189015 - Fax: +33958789015 Do it Once, Use it Twice ~ Do it Twice, Make It Once --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs?hl=en -~----------~----~----~----~------~----~------~--~---
