3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php phpversion() >= "7.0.0beta1" or die(); echo INF / 0,"\n"; echo intdiv(INF,0),"\n"; try { echo intdiv(2,0); } catch (Error $e){ echo $e->getMessage(),"\n"; } try { echo 2 % 0; } catch (Error $e){ echo $e->getMessage(); }
based on SqVGB
Output for 7.0.1 - 7.2.0
Warning: Division by zero in /in/nZCB9 on line 4 INF Warning: intdiv() expects parameter 1 to be integer, float given in /in/nZCB9 on line 5 Division by zero Modulo by zero
Output for 5.3.20 - 7.0.0