3v4l.org

run code in 300+ PHP versions simultaneously
<?php $list = []; for ($i = 0; $i < 100000; $i++) { $list[] = $i; } var_dump(memory_get_peak_usage() / 1024 / 1024);
Output for 8.4.1 - 8.4.2
float(2.3730926513671875)
Output for 8.2.0 - 8.2.26, 8.3.0 - 8.3.14
float(2.373077392578125)
Output for 8.1.0 - 8.1.31
float(4.373374938964844)
Output for 8.0.1 - 8.0.30
float(4.372962951660156)

preferences:
55.16 ms | 409 KiB | 5 Q