3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = array('one','two','tre','four','five'); $newArray = []; foreach ($array as $el) { foreach ($array as $el2) { if ($el === $el2) continue; $newArray[] = $el."/".$el2; } array_shift($array); } print_r($newArray);

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.60.0110.00418.32
8.3.50.0100.00718.21
8.3.40.0070.00718.71
8.3.30.0000.01518.85
8.3.20.0040.00420.03
8.3.10.0050.00322.00
8.3.00.0030.00520.89
8.2.180.0090.00616.38
8.2.170.0220.00018.96
8.2.160.0180.00422.96
8.2.150.0040.00424.18
8.2.140.0090.00024.66
8.2.130.0000.00726.16
8.2.120.0030.00719.57
8.2.110.0070.00422.08
8.2.100.0060.00617.84
8.2.90.0000.00818.15
8.2.80.0040.00418.09
8.2.70.0060.00317.63
8.2.60.0040.00417.92
8.2.50.0080.00018.10
8.2.40.0040.00420.55
8.2.30.0050.00219.21
8.2.20.0040.00418.13
8.2.10.0040.00418.07
8.2.00.0000.00817.98
8.1.280.0100.01025.92
8.1.270.0050.00322.19
8.1.260.0060.00326.35
8.1.250.0070.00028.09
8.1.240.0060.00323.92
8.1.230.0040.00820.89
8.1.220.0000.00917.74
8.1.210.0000.01018.77
8.1.200.0040.00417.25
8.1.190.0030.00517.22
8.1.180.0030.00518.10
8.1.170.0030.00618.70
8.1.160.0050.00318.99
8.1.150.0000.00720.14
8.1.140.0040.00419.64
8.1.130.0030.00318.88
8.1.120.0000.00717.51
8.1.110.0070.00017.46
8.1.100.0000.00717.36
8.1.90.0020.00517.38
8.1.80.0040.00417.35
8.1.70.0030.00317.45
8.1.60.0040.00417.50
8.1.50.0040.00417.41
8.1.40.0040.00417.48
8.1.30.0000.00817.59
8.1.20.0070.00317.61
8.1.10.0040.00417.52
8.1.00.0050.00317.50
8.0.300.0030.00619.79
8.0.290.0050.00216.75
8.0.280.0030.00318.36
8.0.270.0000.00717.16
8.0.260.0070.00018.88
8.0.250.0000.00716.81
8.0.240.0000.00716.93
8.0.230.0030.00316.92
8.0.220.0040.00416.79
8.0.210.0000.00816.80
8.0.200.0000.00716.86
8.0.190.0040.00816.82
8.0.180.0000.00716.94
8.0.170.0070.00016.82
8.0.160.0000.00716.86
8.0.150.0000.00716.79
8.0.140.0040.00416.75
8.0.130.0030.00313.40
8.0.120.0040.00416.75
8.0.110.0000.00716.67
8.0.100.0050.00316.67
8.0.90.0050.00316.71
8.0.80.0090.01216.86
8.0.70.0080.00016.84
8.0.60.0000.00716.95
8.0.50.0090.00016.83
8.0.30.0120.01017.21
8.0.20.0080.01017.40
8.0.10.0070.00016.91
8.0.00.0120.00616.72
7.4.330.0000.00615.55
7.4.320.0060.00016.64
7.4.300.0000.00616.46
7.4.290.0000.00716.40
7.4.280.0070.00016.47
7.4.270.0050.00216.61
7.4.260.0070.00316.48
7.4.250.0040.00416.61
7.4.240.0030.00316.61
7.4.230.0080.00016.50
7.4.220.0090.00616.54
7.4.210.0040.01116.58
7.4.200.0000.00716.64
7.4.160.0090.00616.47
7.4.150.0040.01517.40
7.4.140.0070.00917.86
7.4.130.0080.01216.47
7.4.120.0110.00716.47
7.4.110.0110.00616.57
7.4.100.0120.00616.55
7.4.90.0100.00716.52
7.4.80.0120.00619.39
7.4.70.0060.01516.51
7.4.60.0130.01016.56
7.4.50.0030.01216.59
7.4.40.0130.00316.48
7.4.30.0100.00716.65
7.4.00.0060.00815.12
7.3.330.0000.00513.16
7.3.320.0070.00013.16
7.3.310.0030.00316.35
7.3.300.0000.00616.30
7.3.290.0070.00916.33
7.3.280.0080.00916.33
7.3.270.0160.00617.40
7.3.260.0030.01416.50
7.3.250.0110.00616.35
7.3.240.0120.00616.43
7.3.230.0190.00016.56
7.3.210.0100.00716.52
7.3.200.0070.01116.32
7.3.190.0080.00816.30
7.3.180.0090.00916.59
7.3.170.0060.01016.48
7.3.160.0090.00616.52
7.3.120.0090.01014.93
7.3.110.0060.01215.11
7.3.100.0070.01015.05
7.3.90.0060.00914.60
7.3.80.0030.00614.98
7.3.70.0120.00014.71
7.3.60.0100.00614.97
7.3.50.0060.01015.04
7.3.40.0070.00714.82
7.3.30.0030.01414.67
7.3.20.0110.00416.82
7.3.10.0070.00716.61
7.3.00.0060.00616.76
7.2.330.0120.00616.85
7.2.320.0130.00316.81
7.2.310.0090.00616.44
7.2.300.0120.00616.56
7.2.290.0040.01616.46
7.2.250.0070.01014.85
7.2.240.0000.01515.17
7.2.230.0070.01015.03
7.2.220.0040.01415.07
7.2.210.0090.00615.31
7.2.200.0060.01014.80
7.2.190.0130.00614.83
7.2.180.0070.00715.23
7.2.170.0060.00615.15
7.2.160.0040.01114.89
7.2.150.0060.00616.89
7.2.140.0070.00717.06
7.2.130.0000.01616.75
7.2.120.0030.01016.97
7.2.110.0090.00316.97
7.2.100.0030.00916.79
7.2.90.0070.00716.90
7.2.80.0130.00716.88
7.2.70.0040.01117.00
7.2.60.0070.00716.74
7.2.50.0000.01117.05
7.2.40.0040.01116.92
7.2.30.0080.00416.97
7.2.20.0000.01516.67
7.2.10.0000.01516.84
7.2.00.0090.00616.80
7.1.330.0030.01316.01
7.1.320.0060.00915.83
7.1.310.0040.01215.73
7.1.300.0080.00415.93
7.1.290.0110.00615.59
7.1.280.0080.00615.59
7.1.270.0080.00515.69
7.1.260.0100.00315.92
7.1.250.0070.01015.62
7.1.240.0070.00315.92
7.1.230.0070.00715.81
7.1.220.0030.01015.90
7.1.210.0060.01015.89
7.1.200.0050.01015.85
7.1.190.0060.00315.80
7.1.180.0000.01015.78
7.1.170.0040.00715.82
7.1.160.0060.00315.63
7.1.150.0040.00715.66
7.1.140.0070.00715.96
7.1.130.0080.00415.98
7.1.120.0000.01315.80
7.1.110.0000.01115.86
7.1.100.0060.00915.85
7.1.90.0040.00716.03
7.1.80.2290.00915.88
7.1.70.1980.00915.58
7.1.60.1920.01524.39
7.1.50.2350.01124.27
7.1.40.2250.01324.17
7.1.30.2720.01324.11
7.1.20.2070.00824.32
7.1.10.1940.00615.36
7.1.00.1650.01215.34
7.0.330.0030.01215.46
7.0.320.0090.00615.24
7.0.310.0030.01015.52
7.0.300.0060.00315.29
7.0.290.0030.00615.38
7.0.280.0060.01215.51
7.0.270.0080.00415.23
7.0.260.0000.01615.40
7.0.250.0060.00615.46
7.0.240.0030.01015.40
7.0.230.0090.00615.64
7.0.220.0000.00815.49
7.0.210.0040.01115.55
7.0.200.2260.01115.23
7.0.190.3500.00115.04
7.0.180.1940.01014.97
7.0.170.2890.00914.96
7.0.160.2830.00815.19
7.0.150.1700.01015.11
7.0.140.1950.00714.93
7.0.130.1700.00615.19
7.0.120.1730.01015.13
7.0.110.2140.00814.92
7.0.100.1760.00814.94
7.0.90.1820.00815.07
7.0.80.2030.00815.06
7.0.70.1740.00915.13
7.0.60.1830.00514.98
7.0.50.1970.00714.96
7.0.40.2010.00713.85
7.0.30.1930.00814.18
7.0.20.2110.01013.96
7.0.10.1880.00714.06
7.0.00.2030.01213.96
5.6.400.0030.00714.04
5.6.390.0090.00614.31
5.6.380.0060.00314.31
5.6.370.0070.01014.57
5.6.360.0000.01314.66
5.6.350.0040.00714.13
5.6.340.0130.00014.54
5.6.330.0040.00814.62
5.6.320.0070.00714.02
5.6.310.0030.01414.60
5.6.300.0030.00714.28
5.6.290.0060.00314.15
5.6.280.0060.00314.47
5.6.270.0070.00714.46
5.6.260.0040.01214.30
5.6.250.0000.01014.30
5.6.240.0060.00614.38
5.6.230.0040.00714.60
5.6.220.0000.01314.76
5.6.210.0030.01214.25
5.6.200.0030.00614.34
5.6.190.0100.00314.42
5.6.180.0040.00714.22
5.6.170.0060.00914.41
5.6.160.0080.00414.29
5.6.150.0090.00614.36
5.6.140.0040.01114.69
5.6.130.0060.00914.65
5.6.120.0070.00714.66
5.6.110.0000.01114.48
5.6.100.0040.00814.34
5.6.90.0030.01014.69
5.6.80.0100.00314.35
5.6.70.0100.00314.36
5.6.60.0080.00414.16
5.6.50.0040.00414.60
5.6.40.0070.00314.06
5.6.30.0030.01014.14
5.6.20.0070.00714.29
5.6.10.0060.00614.33
5.6.00.0000.01214.38

preferences:
41.57 ms | 401 KiB | 5 Q