3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php function factorial($n) { if ($n) { return $n * fact($n-1); } else { return 1; } } var_dump(factorial(0));
based on JjqNj
Output for 5.3.19 - 7.3.0rc4
int(1)