3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function quickRandom($length = 16) { $pool = '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ'; $str = substr(str_shuffle(str_repeat($pool, 5)), 0, $length); if ($length > 310) { return $str . quickRandom($length - 310); } return $str; } $i = 100000; while($i--) { quickRandom(311); }
Output for 4.3.0 - 7.1.0