3v4l.org

run code in 500+ PHP versions simultaneously
<?php $numbers = range(0,100000); $start = microtime(true); $found = []; foreach($numbers as $num){ if($num > 1000 && $num < 6000){ $found[] = $num; } } $end = microtime(true); echo "foreach: ".$end - $start."\n"; $start = microtime(true); function FoundValues($num){ return $num > 1000 && $num < 6000; } $found = array_filter($numbers, 'FoundValues'); $end = microtime(true); echo "array_filter: ".$end - $start;
Output for git.master_jit
foreach: 0.0012180805206299 array_filter: 0.0026988983154297
Output for git.master
foreach: 0.0010840892791748 array_filter: 0.0020570755004883

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
44.75 ms | 741 KiB | 4 Q