3v4l.org

run code in 300+ PHP versions simultaneously
<?php set_time_limit(1); $arr = ['a' => 'apple', 'b' => 'banana']; $child = &$arr; $i = 1; foreach ($child AS $key => $fruit) { $child[$i] = $fruit; unset($child[$key]); $i++; } var_dump($child);

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.0040.01118.56
8.3.50.0100.00922.12
8.3.40.0100.01018.69
8.3.30.0100.00318.91
8.3.20.0050.00320.34
8.3.10.0030.00620.39
8.3.00.0080.00019.25
8.2.180.0120.00616.63
8.2.170.0140.00322.96
8.2.160.0160.00020.13
8.2.150.0000.00824.18
8.2.140.0000.00824.66
8.2.130.0000.00726.16
8.2.120.0040.00422.24
8.2.110.0070.00422.05
8.2.100.0070.00417.78
8.2.90.0060.00319.19
8.2.80.0040.00417.97
8.2.70.0080.00017.50
8.2.60.0000.00817.91
8.2.50.0060.00318.07
8.2.40.0050.00319.94
8.2.30.0060.00617.98
8.2.20.0000.00717.81
8.2.10.0040.00418.13
8.2.00.0030.00617.70
8.1.280.0150.00825.92
8.1.270.0030.00623.82
8.1.260.0070.00026.35
8.1.250.0070.00028.09
8.1.240.0060.00323.90
8.1.230.0110.00023.83
8.1.220.0030.00517.79
8.1.210.0050.00318.77
8.1.200.0070.00317.35
8.1.190.0000.00917.25
8.1.180.0000.00818.10
8.1.170.0080.00018.50
8.1.160.0040.00422.05
8.1.150.0000.00818.80
8.1.140.0040.00417.44
8.1.130.0030.00317.75
8.1.120.0030.00517.48
8.1.110.0040.00417.37
8.1.100.0040.00417.36
8.1.90.0050.00217.30
8.1.80.0040.00417.36
8.1.70.0000.00717.36
8.1.60.0000.00817.58
8.1.50.0000.00817.53
8.1.40.0060.00317.52
8.1.30.0030.00617.55
8.1.20.0040.00417.57
8.1.10.0000.00717.55
8.1.00.0120.00017.31
8.0.300.0070.00018.77
8.0.290.0040.00416.75
8.0.280.0040.00418.52
8.0.270.0040.00416.74
8.0.260.0030.00317.25
8.0.250.0000.00716.98
8.0.240.0000.00716.90
8.0.230.0070.00016.82
8.0.220.0000.00716.82
8.0.210.0000.00716.88
8.0.200.0000.00916.82
8.0.190.0020.00516.93
8.0.180.0040.00416.83
8.0.170.0050.00316.93
8.0.160.0070.00016.93
8.0.150.0000.00716.66
8.0.140.0000.00816.80
8.0.130.0000.00613.30
8.0.120.0000.00916.82
8.0.110.0000.00816.80
8.0.100.0040.00416.69
8.0.90.0040.00416.83
8.0.80.0120.00916.77
8.0.70.0000.00716.92
8.0.60.0000.00716.77
8.0.50.0000.00716.71
8.0.30.0140.00416.87
8.0.20.0120.00617.40
8.0.10.0040.00417.01
8.0.00.0060.01316.82
7.4.330.0020.00215.09
7.4.320.0030.00316.50
7.4.300.0030.00316.64
7.4.290.0030.00316.53
7.4.280.0000.00816.60
7.4.270.0030.00316.46
7.4.260.0040.00416.39
7.4.250.0040.00416.46
7.4.240.0030.00316.48
7.4.230.0030.00316.64
7.4.220.0040.01416.45
7.4.210.0070.01116.47
7.4.200.0000.00716.71
7.4.160.0120.00916.39
7.4.150.0130.00317.40
7.4.140.0120.00817.86
7.4.130.0090.00916.40
7.4.120.0040.01316.54
7.4.110.0060.01016.46
7.4.100.0100.00716.48
7.4.90.0050.01216.42
7.4.80.0100.00619.39
7.4.70.0100.00616.44
7.4.60.0170.00716.58
7.4.50.0000.00816.57
7.4.40.0130.00316.43
7.4.30.0110.00616.44
7.4.00.0070.01114.94
7.3.330.0030.00313.24
7.3.320.0060.00013.18
7.3.310.0000.00716.41
7.3.300.0030.00516.35
7.3.290.0040.01116.35
7.3.280.0090.00616.36
7.3.270.0090.00917.40
7.3.260.0090.00916.42
7.3.250.0100.00616.31
7.3.240.0100.00716.49
7.3.230.0110.00716.39
7.3.210.0130.00316.23
7.3.200.0070.01019.39
7.3.190.0140.00816.54
7.3.180.0120.00416.23
7.3.170.0060.00916.40
7.3.160.0080.00816.39
7.3.120.0070.00714.88
7.3.110.0130.00614.84
7.3.100.0030.01514.88
7.3.90.0040.01114.83
7.3.80.0110.00415.19
7.3.70.0060.00614.95
7.3.60.0070.00714.64
7.3.50.0000.00914.82
7.3.40.0030.01214.72
7.3.30.0030.01014.84
7.3.20.0090.00616.66
7.3.10.0070.00716.83
7.3.00.0070.00716.79
7.2.330.0040.01516.72
7.2.320.0070.01016.51
7.2.310.0100.01316.74
7.2.300.0060.01216.63
7.2.290.0120.00616.57
7.2.250.0030.01214.87
7.2.240.0130.00715.16
7.2.230.0090.00615.13
7.2.220.0110.00414.95
7.2.210.0000.01114.97
7.2.200.0120.00014.93
7.2.190.0000.01614.79
7.2.180.0080.00815.10
7.2.170.0090.00015.09
7.2.60.0070.01016.95
7.2.00.0130.00419.68
7.1.330.0070.00715.72
7.1.320.0000.01115.93
7.1.310.0080.00815.76
7.1.300.0090.00615.75
7.1.290.0070.00415.66
7.1.280.0070.00315.57
7.1.270.0050.00515.86
7.1.260.0070.00715.68
7.1.200.0030.01215.68
7.1.100.0000.01118.17
7.1.70.0000.00717.25
7.1.60.0110.01419.32
7.1.50.0100.01316.81
7.1.00.0100.07022.45
7.0.200.0000.00816.90
7.0.140.0070.07021.97
7.0.120.0000.07722.05
7.0.110.0070.07322.13
7.0.100.0000.07722.02
7.0.90.0070.07322.05
7.0.80.0030.08722.04
7.0.70.0000.07722.21
7.0.60.0070.07022.00
7.0.50.0070.07022.22
7.0.40.0070.07022.02
7.0.30.0030.07322.02
7.0.20.0030.07322.17
7.0.10.0030.07322.07
7.0.00.0070.07022.03
5.6.280.0031.07721.07
5.6.260.0031.08020.88
5.6.250.0071.07720.86
5.6.240.0031.07321.03
5.6.230.0031.07321.09
5.6.220.0031.08021.08
5.6.210.0001.08020.64
5.6.200.0031.06320.92
5.6.190.0001.05020.94
5.6.180.0001.07320.89
5.6.170.0031.05720.92
5.6.160.0001.08020.75
5.6.150.0001.08720.74
5.6.140.0031.08020.94
5.6.130.0031.07720.82
5.6.120.0001.08720.93
5.6.110.0001.08720.82
5.6.100.0031.08020.77
5.6.90.0031.07720.95
5.6.80.0071.06020.41
5.6.70.0071.05720.40
5.6.60.0071.07320.17
5.6.50.0071.05020.36
5.6.40.0001.05720.44
5.6.30.0071.07720.36
5.6.20.0001.08020.38
5.6.10.0031.06320.35
5.6.00.0001.08020.39
5.5.380.0031.07317.66
5.5.370.0031.07317.58
5.5.360.0001.08017.39
5.5.350.0001.07717.62
5.5.340.0131.07017.89
5.5.330.0031.06718.09
5.5.320.0001.08018.16
5.5.310.0071.07318.00
5.5.300.0031.06318.09
5.5.290.0001.08317.84
5.5.280.0031.07717.86
5.5.270.0031.07718.12
5.5.260.0001.08018.24
5.5.250.0001.05017.80
5.5.240.0001.07317.51
5.5.230.0001.06717.23
5.5.220.0031.07317.27
5.5.210.0031.07017.14
5.5.200.0001.07317.21
5.5.190.0001.08017.52
5.5.180.0071.07317.34
5.5.160.0001.06017.22
5.5.150.0031.07017.37
5.5.140.0001.07317.48
5.5.130.0031.06017.33
5.5.120.0031.07317.23
5.5.110.0001.07717.19
5.5.100.0001.07717.39
5.5.90.0001.05317.12
5.5.80.0031.07017.23
5.5.70.0031.07717.08
5.5.60.0001.07317.13
5.5.50.0071.06717.25
5.5.40.0001.05717.25
5.5.30.0001.07717.33
5.5.20.0001.07717.48
5.5.10.0001.07717.22
5.5.00.0001.07717.41
5.4.450.0001.07719.30
5.4.440.0101.07319.35
5.4.430.0101.05019.34
5.4.420.0031.07719.30
5.4.410.0071.07019.31
5.4.400.0071.07019.07
5.4.390.0001.07719.07
5.4.380.0031.05018.95
5.4.370.0031.06719.00
5.4.360.0001.07718.91
5.4.350.0001.07719.11
5.4.340.0001.07718.98
5.4.320.0031.07318.95
5.4.310.0031.07018.93
5.4.300.0031.07319.00
5.4.290.0001.07719.07
5.4.280.0001.08018.94
5.4.270.0031.07019.15
5.4.260.0031.06019.11
5.4.250.0031.07018.99
5.4.240.0031.07319.02
5.4.230.0071.07018.92
5.4.220.0001.07718.98
5.4.210.0101.06319.10
5.4.200.0001.07319.10
5.4.190.0001.07319.08
5.4.180.0071.05718.99
5.4.170.0031.07319.23
5.4.160.0001.07019.15
5.4.150.0001.08019.05
5.4.140.0031.06316.36
5.4.130.0001.06016.30
5.4.120.0031.06716.30
5.4.110.0071.06716.13
5.4.100.0071.06716.50
5.4.90.0001.07316.34
5.4.80.0001.07016.48
5.4.70.0001.07016.21
5.4.60.0071.06716.20
5.4.50.0001.07316.10
5.4.40.0071.06316.30
5.4.30.0071.06316.19
5.4.20.0071.06316.09
5.4.10.0031.06716.46
5.4.00.0071.06015.89
5.3.290.0030.06014.61
5.3.280.0030.06714.39
5.3.270.0000.07314.54
5.3.260.0000.07314.52
5.3.250.0000.07014.53
5.3.240.0030.06714.47
5.3.230.0070.06314.52
5.3.220.0000.07014.51
5.3.210.0000.07014.51
5.3.200.0070.06014.43
5.3.190.0030.06714.59
5.3.180.0030.06314.64
5.3.170.0030.06714.46
5.3.160.0000.06714.65
5.3.150.0030.06314.46
5.3.140.0000.07014.49
5.3.130.0070.04714.43
5.3.120.0070.06314.49
5.3.110.0070.06714.56
5.3.100.0000.06713.91
5.3.90.0000.06713.92
5.3.80.0030.06014.11
5.3.70.0070.06013.92
5.3.60.0030.06314.10
5.3.50.0000.06713.95
5.3.40.0000.06713.95
5.3.30.0000.06713.80
5.3.20.0030.06313.59
5.3.10.0070.05713.72
5.3.00.0000.05713.65
5.2.170.0030.05711.15
5.2.160.0000.05711.20
5.2.150.0030.05311.08
5.2.140.0030.05711.21
5.2.130.0000.05311.12
5.2.120.0000.05311.11
5.2.110.0030.05311.03
5.2.100.0000.05711.05
5.2.90.0030.05311.12
5.2.80.0000.05711.10
5.2.70.0000.05710.88
5.2.60.0030.04710.85
5.2.50.0000.05711.07
5.2.40.0030.05310.90
5.2.30.0000.05711.03
5.2.20.0000.05011.04
5.2.10.0030.05010.80
5.2.00.0000.04710.63
5.1.60.0000.0379.77
5.1.50.0030.03710.05
5.1.40.0000.04710.04
5.1.30.0030.04710.29
5.1.20.0000.05010.36
5.1.10.0000.05010.00
5.1.00.0000.05010.14
5.0.50.0030.0379.70
5.0.40.0030.0309.70
5.0.30.0000.0609.70
5.0.20.0000.0409.70
5.0.10.0070.0339.70
5.0.00.0000.0579.70
4.4.90.0000.0309.70
4.4.80.0000.0309.70
4.4.70.0030.0279.70
4.4.60.0030.0309.70
4.4.50.0000.0309.70
4.4.40.0030.0379.70
4.4.30.0030.0309.70
4.4.20.0030.0239.70
4.4.10.0100.0239.70
4.4.00.0030.0439.70
4.3.110.0000.0279.70
4.3.100.0000.0309.70
4.3.90.0070.0239.70
4.3.80.0070.0409.70
4.3.70.0000.0309.70
4.3.60.0030.0279.70
4.3.50.0000.0339.70
4.3.40.0000.0479.70
4.3.30.0000.0339.70
4.3.20.0030.0309.70
4.3.10.0000.0339.70
4.3.00.0000.0279.70

preferences:
47.63 ms | 401 KiB | 5 Q