3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $prefix2op = array('53' => 1, '54' => 2, '55' => 3, '50' => 3); function getDefaultOp($number) { global $prefix2op; $op3 = (int) substr($number, 0, 3); if (!($op3 >= 505 && $op3 <= 507)) return 0; $s = substr($number, 0, 2); return $prefix2op[$s]; } $a = array(); for($i = 0; $i < 10000; $i++){ $a[] = getDefaultOp(5073456108 + $i); } echo sizeof($a);
Output for 4.3.0 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
10000