3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php if(!function_exists('pCount')){ function pCount(){ global $x; if($x>5){ sleep(1); pCount(); }else{ $x++; return; } } } echo $x."<br>"; pCount(); echo $x."<br>";
Output for 5.0.4 - 7.1.0
Notice: Undefined variable: x in /in/krjHW on line 15 <br>1<br>
Output for 4.3.0 - 5.0.3
Notice: Undefined variable: x in /in/krjHW on line 15 <br>1<br>