3v4l.org

run code in 300+ PHP versions simultaneously
<?php for ($i = 1; $i < 256; $i++) { $char = chr($i); echo $i . ' : ' . (($i >= '0') ? 'true' : 'false') . "\n"; } foreach (array('a','b','c','d','e','f','g','h','i','j','k','l','m','n','o','p','q','r','s','t','u','v','w','x','y','z') as $) { echo $l . ' : ' . (($l >= '0') ? 'true' : 'false') . "\n"; } for ($i = 1; $i < 1000; $i++) { echo $i . ' : ' . (($i >= '0') ? 'true' : 'false') . "\n"; }
Output for 5.4.0 - 5.4.31
Parse error: syntax error, unexpected ')', expecting variable (T_VARIABLE) or '$' in /in/5bnWF on line 9
Process exited with code 255.
Output for 5.3.0 - 5.3.28
Parse error: syntax error, unexpected ')', expecting T_VARIABLE or '$' in /in/5bnWF on line 9
Process exited with code 255.

preferences:
181.4 ms | 1395 KiB | 68 Q