3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $result = 'foo'; for ($i = 0; $i < 100; ++$i) { $result .= $result; } var_dump(strlen($result));
based on VfCqo
Output for 7.0.0 - 7.1.0
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 50331680 bytes) in /in/r6URS on line 6
Process exited with code 255.
Output for 5.2.2 - 5.6.28
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 100663297 bytes) in /in/r6URS on line 6
Process exited with code 255.
Output for 5.2.1
No input file specified.
Process exited with code 255.
Output for 5.2.0
Fatal error: Out of memory (allocated 805830656) (tried to allocate 1610612737 bytes) in /in/r6URS on line 6
Process exited with code 255.
Output for 5.1.6
FATAL: erealloc(): Unable to allocate 3221225473 bytes
Process exited with code 1.
Output for 4.3.0 - 5.1.5

Process exited with code 137.