3v4l.org

run code in 300+ PHP versions simultaneously
<?php $chanstring = "\x01-07 / %x08-09 / %x0B-0C / %x0E-1F / %x21-2B / %x2D-39 / %x3B-FF"; function arrFromString($string) { $explosion = explode('-',$string); $lower = str_split($explosion[0]); $upper = str_split($explosion[1]); $arr = array(); $curr = $lower; while (implode('',$curr) != implode('',$upper)) { $arr[] = chr(hexdec(implode('',$curr))); if (is_numeric($curr[1])) { $curr[1]++; if ($curr[1] > 9) { $curr[1] = 'A'; } } else { $curr[1] = chr(ord($curr[1]) + 1); if ($curr[1] === 'G') { $curr[1] = 0; if (is_numeric($curr[0])) { $curr[0]++; if ($curr[0] > 9) { $curr[0] = 'A'; } } else { $curr[1] = chr(ord($curr[1]) + 1); } } } } $arr[] = chr(hexdec(implode('',$curr))); return implode(' - ',$arr); } echo implode(' / ',array_map('arrFromString', array('01-07','08-09','0B-0C','0E-1F','21-2B','2D-39','3B-FF')));
Output for 8.2.0 - 8.2.17, 8.3.0 - 8.3.4
Fatal error: Out of memory (allocated 18878464 bytes) (tried to allocate 33554440 bytes) in /in/K0YoB on line 14 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 18878464) (tried to allocate 33554440 bytes) in /in/K0YoB on line 14 mmap() failed: [12] Cannot allocate memory mmap() failed: [12] Cannot allocate memory
Process exited with code 255.
Output for 7.2.29 - 7.2.33, 7.3.16 - 7.3.31, 7.4.3 - 7.4.25, 7.4.27 - 7.4.33, 8.0.0 - 8.0.12, 8.0.14 - 8.0.30, 8.1.0 - 8.1.1
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 67108872 bytes) in /in/K0YoB on line 14
Process exited with code 255.
Output for 7.3.32 - 7.3.33, 7.4.26, 8.0.13
Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 134217736 bytes) in /in/K0YoB on line 14
Process exited with code 255.
Output for 7.0.0 - 7.0.5
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 33554440 bytes) in /in/K0YoB on line 14
Process exited with code 255.
Output for 5.5.0 - 5.5.34, 5.6.0 - 5.6.20
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 72 bytes) in /in/K0YoB on line 14
Process exited with code 255.
Output for 5.4.0 - 5.4.45
Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 72 bytes) in /in/K0YoB on line 14
Process exited with code 255.
Output for 5.3.0 - 5.3.29
Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 32 bytes) in /in/K0YoB on line 13
Process exited with code 255.

preferences:
187.34 ms | 401 KiB | 272 Q