3v4l.org

run code in 300+ PHP versions simultaneously
<?php $items = range('a', 'z'); function permute($items, $perms = array( )) { if (empty($items)) { var_dump($perms); } else { for ($i = count($items) - 1; $i >= 0; --$i) { $newitems = $items; $newperms = $perms; list($foo) = array_splice($newitems, $i, 1); array_unshift($newperms, $foo); permute($newitems, $newperms); } } } permute($items);

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)
8.3.70.0390.00318.16
8.3.60.0350.00718.43
8.3.50.0400.00621.89
8.3.40.0460.01018.71
8.3.30.0420.01719.09
8.3.20.0120.00320.25
8.3.10.0120.00621.95
8.3.00.0130.01022.43
8.2.190.0190.01316.58
8.2.180.0370.01716.50
8.2.170.0350.01322.96
8.2.160.0170.01720.90
8.2.150.0100.00624.18
8.2.140.0150.00624.66
8.2.130.0160.00626.16
8.2.120.0110.01117.63
8.2.110.0180.01120.52
8.2.100.0160.01317.91
8.2.90.0070.00718.22
8.2.80.0110.00317.97
8.2.70.0040.01517.63
8.2.60.0090.00618.04
8.2.50.0110.00418.07
8.2.40.0160.00318.16
8.2.30.0030.01018.09
8.2.20.0100.00617.79
8.2.10.0120.00319.60
8.2.00.0140.00317.70
8.1.280.0450.01125.92
8.1.270.0110.00422.04
8.1.260.0230.00026.35
8.1.250.0030.01028.09
8.1.240.0310.00322.19
8.1.230.0170.01720.80
8.1.220.0060.00917.74
8.1.210.0100.00318.91
8.1.200.0070.01117.23
8.1.190.0090.00617.55
8.1.180.0100.01018.10
8.1.170.0110.00718.58
8.1.160.0040.01122.06
8.1.150.0070.00718.67
8.1.140.0120.00317.54
8.1.130.0140.00317.92
8.1.120.0140.00517.52
8.1.110.0160.00417.54
8.1.100.0070.00717.56
8.1.90.0110.01117.54
8.1.80.0110.00417.45
8.1.70.0030.01017.55
8.1.60.0140.00317.61
8.1.50.0030.00717.48
8.1.40.0070.00717.50
8.1.30.0110.00417.70
8.1.20.0110.00417.69
8.1.10.0160.00517.55
8.1.00.0120.00317.48
8.0.300.0070.00719.97
8.0.290.0030.01416.93
8.0.280.0030.01018.25
8.0.270.0060.00617.09
8.0.260.0090.01316.78
8.0.250.0050.01416.82
8.0.240.0070.01016.83
8.0.230.0100.00316.66
8.0.220.0070.00716.66
8.0.210.0100.00716.79
8.0.200.0090.00316.79
8.0.190.0100.00716.75
8.0.180.0000.01416.70
8.0.170.0080.01216.91
8.0.160.0100.00416.85
8.0.150.0140.00016.66
8.0.140.0070.01016.67
8.0.130.0070.00313.35
8.0.120.0090.00616.81
8.0.110.0080.01216.81
8.0.100.0100.00316.64
8.0.90.0110.00316.83
8.0.80.0170.03916.75
8.0.70.0090.00916.86
8.0.60.0100.00716.66
8.0.50.0070.00716.88
8.0.30.0560.03717.07
8.0.20.0590.02917.40
8.0.10.0090.00916.95
8.0.00.0570.02916.55
7.4.330.0060.00315.09
7.4.320.0030.00716.51
7.4.300.0030.00716.41
7.4.290.0070.01016.49
7.4.280.0090.00316.30
7.4.270.0230.00416.48
7.4.260.0100.00316.41
7.4.250.0180.00516.41
7.4.240.0120.00516.53
7.4.230.0030.01016.21
7.4.220.0300.03016.49
7.4.210.0280.03016.51
7.4.200.0110.00016.50
7.4.190.0030.01016.30
7.4.160.0760.01816.54
7.4.150.0670.03617.40
7.4.140.0580.03917.86
7.4.130.0610.03616.44
7.4.120.0410.03216.51
7.4.110.0450.01916.38
7.4.100.0560.04016.39
7.4.90.0380.03216.45
7.4.80.0330.05716.25
7.4.70.0420.04116.45
7.4.60.0480.03016.30
7.4.50.0240.01016.40
7.4.40.0070.01422.77
7.4.30.0320.01616.41
7.4.00.0120.01914.66
7.3.330.0080.00413.34
7.3.320.0160.00013.14
7.3.310.0030.00916.27
7.3.300.0080.00816.13
7.3.290.0230.03916.27
7.3.280.0280.02816.27
7.3.270.0360.03217.40
7.3.260.0220.02116.43
7.3.250.0430.02316.42
7.3.240.0740.03616.38
7.3.230.0910.04116.39
7.3.210.0980.04016.61
7.3.200.0650.03019.39
7.3.190.0650.04116.14
7.3.180.0410.03716.27
7.3.170.0210.03816.30
7.3.160.0170.04516.14
7.3.120.0130.01914.77
7.2.330.0580.02616.67
7.2.320.0360.02316.73
7.2.310.0320.03016.72
7.2.300.0580.03216.81
7.2.290.0400.05416.65
7.2.60.0210.01116.85
7.1.200.0110.01815.70
7.1.100.0170.00617.86
7.1.70.0080.00417.29
7.1.60.0160.01319.82
7.1.50.0220.00916.89
7.0.200.0180.00916.72

preferences:
35.07 ms | 401 KiB | 5 Q