3v4l.org

run code in 300+ PHP versions simultaneously
<?php $max = 100000; function xrange($len) { $i = 0; while ($i < $len; $i++) {        yield $i;        $i++;    }    return; } $a = $b = $c = 0; foreach (xrange($max) as $i) { $a = $a + $b + $i; $b = $a * 5678 * $i; $c = $i * $i; }
Output for 5.3.0 - 5.3.28, 5.4.0 - 5.4.25
Parse error: syntax error, unexpected ';' in /in/mXiQN on line 5
Process exited with code 255.

preferences:
209.93 ms | 1395 KiB | 62 Q