3v4l.org

run code in 300+ PHP versions simultaneously
<?php $start = microtime(true); $arr = []; for ($i = 0; $i < 1000; $i++) { array_push($arr, $i); } $end = microtime(true); echo number_format($end - $start, 8, '.', '') . "\n"; unset($arr); $start = microtime(true); $arr = []; for ($i = 0; $i < 1000; $i++) { $arr[] = $i; } $end = microtime(true); echo number_format($end - $start, 8, '.', '') . "\n";

preferences:
39.5 ms | 406 KiB | 5 Q