Random number generator (included): Difference between revisions

Line 332:
=={{header|Perl}}==
Perl's <code>[http://perldoc.perl.org/functions/rand.html rand]</code> function will try and call <code>[http://www.opengroup.org/onlinepubs/007908775/xsh/drand48.html drand48]</code>, <code>[http://www.opengroup.org/onlinepubs/000095399/functions/random.html random]</code> or <code>[http://www.opengroup.org/onlinepubs/000095399/functions/rand.html rand]</code> from the C library <code>[http://www.opengroup.org/onlinepubs/000095399/basedefs/stdlib.h.html stdlib.h]</code> in that order.
=={{header|Perl 6}}==
Currently the implementation underlying the <tt>rand</tt> function is platform dependent.
In the [[niecza]] implementation it uses the built-in <tt>Random</tt> class, (Knuth subtractive algorithm) but the exact semantics vary between mono and Microsoft's versions. In the [[rakudo]] implementation it is also platform-dependent; on the [[parrot]] backend, <tt>rand48</tt> is used. The JVM backend uses that platform's SecureRandom class.
 
This is all subject to change, since we're still designing the language...
 
=={{header|PHP}}==
Anonymous user