3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php foreach (['a' => 1,'b' => 2,'c' => 3] as $row) { foreach ($row as $k => $row) { echo "$k => $row\n"; } }
Output for 5.4.11 - 7.2.6
Warning: Invalid argument supplied for foreach() in /in/LGBvF on line 5 Warning: Invalid argument supplied for foreach() in /in/LGBvF on line 5 Warning: Invalid argument supplied for foreach() in /in/LGBvF on line 5
Output for 5.3.21 - 5.3.29
Parse error: syntax error, unexpected '[' in /in/LGBvF on line 3
Process exited with code 255.