3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $t1 = microtime(true); for($a = 0; $a < 1000; $a++) { for($i = 1; $i < 1000; $i++) { $varArray1[$a][] = $i ** ($i * 2); if($i%2==0&&$a%5==0) $varArray[$a][] = $i ** ($i * 2); else $varArray2[$a][] = $i ** ($i * 4); } } for($i = 0; $i < 1000; $i += 2) array_diff($varArray1[$i],$varArray2[$i+1]); $t2 = microtime(true); echo $t2 - $t1;
based on IR3eK
Output for 7.0.0 - 7.1.0
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 36864 bytes) in /in/cd2RG on line 5
Process exited with code 255.
Output for 5.6.7 - 5.6.28
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 72 bytes) in /in/cd2RG on line 5
Process exited with code 255.
Output for 4.4.2 - 4.4.9, 5.1.0 - 5.5.35
Parse error: syntax error, unexpected '*' in /in/cd2RG on line 5
Process exited with code 255.
Output for 4.3.0 - 4.3.1, 4.3.5 - 4.4.1, 5.0.0 - 5.0.5
Parse error: parse error, unexpected '*' in /in/cd2RG on line 5
Process exited with code 255.
Output for 4.3.2 - 4.3.4
Parse error: parse error in /in/cd2RG on line 5
Process exited with code 255.