3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php for($i=0;$i>100;$i++) { $c = mt_rand(1,3); if($c == 1) { $one++; } elseif($c == 2) { $two++; } elseif($c=3) { $three++; } } echo "one {$one}; two {$two}; three {$three}";
based on LjrsE
Output for 5.0.4 - 7.1.0
Notice: Undefined variable: one in /in/I12R4 on line 8 Notice: Undefined variable: two in /in/I12R4 on line 8 Notice: Undefined variable: three in /in/I12R4 on line 8 one ; two ; three
Output for 4.3.0 - 5.0.3
Notice: Undefined variable: one in /in/I12R4 on line 8 Notice: Undefined variable: two in /in/I12R4 on line 8 Notice: Undefined variable: three in /in/I12R4 on line 8 one ; two ; three