3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = array(1,2,3,4,5,6); foreach($a as $b) {echo $b mod 2; echo "<br/>"}
Output for 5.4.0 - 5.4.20
Parse error: syntax error, unexpected 'mod' (T_STRING), expecting ',' or ';' in /in/bmnrh on line 3
Process exited with code 255.
Output for 5.3.0 - 5.3.27
Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /in/bmnrh on line 3
Process exited with code 255.

preferences:
180.78 ms | 1386 KiB | 56 Q