3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php function divide($num1, $num2) { if ($num1 == 0 || $num2 == 0) return 0; if ($num1 == '' || $num2 == '') return 0; return $num1 / $num2; } divide(1, 2); divide("", 2);
Output for 4.3.0 - 7.2.0