3v4l.org

run code in 300+ PHP versions simultaneously
<?php $obj = new StdClass; $obj->fn = function($arg) { return "Hello $arg"; }; echo ($obj->fn)('World'); class Bla { public $fn = function($arg="Bu"){return "Hello lo $arg"; }; } $bla = new Bla; echo ($bla->fun)('Wa');

Here you find the average performance (time & memory) of each version. A grayed out version indicates it didn't complete successfully (based on exit-code).

VersionSystem time (s)User time (s)Memory (MiB)
7.0.20.0400.07020.05
7.0.10.0100.08020.16
7.0.00.0070.06020.11
5.6.170.0230.03720.54
5.6.160.0170.07320.50
5.6.150.0000.04318.15
5.6.140.0070.05018.15
5.6.130.0070.08018.23
5.6.120.0130.08721.00
5.6.110.0170.04721.07
5.6.100.0100.08021.14
5.6.90.0130.07021.04
5.6.80.0100.07720.39
5.5.310.0330.07020.38
5.5.300.0170.07018.02
5.5.290.0070.04318.09
5.5.280.0070.08020.86
5.5.270.0070.08320.88
5.5.260.0070.06320.80
5.5.250.0300.06020.55
5.5.240.4270.04020.16

preferences:
135.39 ms | 1394 KiB | 7 Q