3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $x = array(-3, 3, 5, 7); function array_max($array) { $max = $array[0]; for ($i = 0; $i < count($array); $i++) { if ($array[$i] > $max) { $max = $array[$i]; } } echo $max; } array_max($x);
based on eLBYD
Output for 4.3.0 - 7.1.7
7