3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = array(&$a); function fill (&$a, $i = 3) { if (!$i--) return; foreach ($a as &$tmp) { $tmp = array($tmp ,&$a); //var_dump($a); fill($tmp); } } fill($a);
Output for 7.0.20, 7.1.5 - 7.1.10, 7.2.0 - 7.2.33, 7.3.12 - 7.3.33, 7.4.0 - 7.4.4, 7.4.6 - 7.4.23, 7.4.25 - 7.4.27, 7.4.33, 8.0.0, 8.0.2 - 8.0.6, 8.0.8, 8.0.12 - 8.0.18, 8.0.20 - 8.0.21, 8.0.23 - 8.0.24, 8.0.27 - 8.0.29, 8.1.28, 8.2.17 - 8.2.18, 8.3.5 - 8.3.6

Process exited with code 137.
Output for 8.2.0 - 8.2.16, 8.3.0 - 8.3.4
Fatal error: Out of memory (allocated 31457280 bytes) (tried to allocate 978944 bytes) in /in/c6NjS on line 5 mmap() failed: [12] Cannot allocate memory mmap() failed: [12] Cannot allocate memory
Process exited with code 255.
Output for 8.1.2 - 8.1.27
Fatal error: Out of memory (allocated 31457280) (tried to allocate 741376 bytes) in /in/c6NjS on line 5 mmap() failed: [12] Cannot allocate memory mmap() failed: [12] Cannot allocate memory
Process exited with code 255.
Output for 7.4.5, 7.4.24, 7.4.28 - 7.4.32, 8.0.1, 8.0.7, 8.0.9, 8.0.11, 8.0.19, 8.0.22, 8.0.25 - 8.0.26, 8.0.30, 8.1.0 - 8.1.1
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 1634304 bytes) in /in/c6NjS on line 5
Process exited with code 255.
Output for 8.0.10
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 1634304 bytes) in /in/c6NjS on line 5
Process exited with code 137.
Output for 5.4.0 - 5.4.14
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 72 bytes) in /in/c6NjS on line 6
Process exited with code 255.
Output for 5.3.11 - 5.3.24
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 32 bytes) in /in/c6NjS on line 6
Process exited with code 255.
Output for 5.3.0 - 5.3.10
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 71 bytes) in /in/c6NjS on line 6
Process exited with code 255.

preferences:
168.7 ms | 401 KiB | 188 Q