3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = array( array( array( array( 'leaf-0-0-0-0', 'leaf-0-0-0-1' ), 'leaf-0-0-0' ), array( array( 'leaf-0-1-0-0', 'leaf-0-1-0-1' ), 'leaf-0-1-0' ), 'leaf-0-0' ) ); $iterator = new RecursiveIteratorIterator( new RecursiveArrayIterator($array), LEAVES_ONLY ); foreach ($iterator as $key => $leaf) { echo "$key => $leaf", PHP_EOL; }

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.0090.00616.75
8.3.50.0160.00621.15
8.3.40.0030.01318.97
8.3.30.0140.00018.84
8.3.20.0090.00020.16
8.3.10.0090.00023.54
8.3.00.0040.00419.56
8.2.180.0070.00716.63
8.2.170.0070.01422.96
8.2.160.0100.00320.38
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0000.00826.16
8.2.120.0060.00317.50
8.2.110.0030.00622.20
8.2.100.0000.01217.75
8.2.90.0050.00319.21
8.2.80.0040.00417.97
8.2.70.0050.00317.61
8.2.60.0050.00317.80
8.2.50.0050.00318.07
8.2.40.0050.00321.03
8.2.30.0070.00019.91
8.2.20.0000.00717.73
8.2.10.0000.00717.98
8.2.00.0070.00017.99
8.1.280.0140.00625.92
8.1.270.0040.01420.01
8.1.260.0050.00326.35
8.1.250.0080.00028.09
8.1.240.0030.00622.32
8.1.230.0090.00317.42
8.1.220.0000.00717.79
8.1.210.0040.00418.77
8.1.200.0130.00017.13
8.1.190.0000.00817.25
8.1.180.0040.00418.10
8.1.170.0040.00418.63
8.1.160.0060.00322.02
8.1.150.0000.00718.79
8.1.140.0050.00317.48
8.1.130.0000.00817.54
8.1.120.0030.00517.46
8.1.110.0070.00017.46
8.1.100.0050.00317.45
8.1.90.0030.00517.50
8.1.80.0030.00417.43
8.1.70.0030.00317.43
8.1.60.0030.00617.61
8.1.50.0080.00017.40
8.1.40.0030.00617.54
8.1.30.0000.00917.66
8.1.20.0000.00717.54
8.1.10.0000.00717.64
8.1.00.0040.00417.52
8.0.300.0090.00018.77
8.0.290.0000.00716.75
8.0.280.0000.00718.36
8.0.270.0000.00717.19
8.0.260.0000.00617.29
8.0.250.0000.00717.07
8.0.240.0000.00816.93
8.0.230.0000.00716.98
8.0.220.0040.00416.91
8.0.210.0040.00416.93
8.0.200.0050.00317.06
8.0.190.0030.00617.02
8.0.180.0000.00816.86
8.0.170.0000.00716.86
8.0.160.0040.00416.85
8.0.150.0040.00416.87
8.0.140.0000.00716.84
8.0.130.0000.00513.39
8.0.120.0080.00016.88
8.0.110.0000.00716.88
8.0.100.0040.00416.82
8.0.90.0070.00016.73
8.0.80.0060.00916.90
8.0.70.0050.00216.99
8.0.60.0000.00816.76
8.0.50.0030.00516.94
8.0.30.0090.00717.27
8.0.20.0110.00717.40
8.0.10.0000.00816.97
8.0.00.0100.01016.95
7.4.330.0030.00315.08
7.4.320.0060.00016.49
7.4.300.0000.00716.65
7.4.290.0030.00316.50
7.4.280.0000.00716.55
7.4.270.0040.00216.53
7.4.260.0070.00016.57
7.4.250.0070.00016.49
7.4.240.0040.00416.59
7.4.230.0030.00316.59
7.4.220.0170.01016.41
7.4.210.0120.00316.64
7.4.200.0030.00316.31
7.4.160.0090.01216.49
7.4.150.0090.01317.40
7.4.140.0120.00517.86
7.4.130.0110.01016.50
7.4.120.0050.01216.56
7.4.110.0030.01616.59
7.4.100.0160.00316.52
7.4.90.0060.01516.71
7.4.80.0040.01719.39
7.4.70.0150.00616.50
7.4.60.0110.01116.41
7.4.50.0000.00816.52
7.4.40.0100.00716.34
7.4.30.0130.01016.69
7.4.00.0080.01015.01
7.3.330.0000.00513.14
7.3.320.0030.00313.04
7.3.310.0000.00716.14
7.3.300.0000.00716.29
7.3.290.0090.00916.32
7.3.280.0130.00816.28
7.3.270.0100.00617.40
7.3.260.0100.00716.38
7.3.250.0070.01116.51
7.3.240.0040.01316.54
7.3.230.0100.00616.39
7.3.210.0140.00316.30
7.3.200.0140.00616.27
7.3.190.0130.00616.46
7.3.180.0050.01116.33
7.3.170.0110.00616.50
7.3.160.0150.00616.45
7.3.120.0050.01314.85
7.3.110.0050.01314.76
7.3.100.0100.00414.71
7.3.90.0050.00914.88
7.3.80.0080.00414.87
7.3.70.0050.00614.76
7.3.60.0050.00814.81
7.3.50.0100.00314.72
7.3.40.0030.01114.71
7.3.30.0060.00714.80
7.3.20.0050.00816.66
7.3.10.0060.00716.50
7.3.00.0070.00616.59
7.2.330.0120.01216.37
7.2.320.0160.00716.80
7.2.310.0100.00716.67
7.2.300.0140.00616.36
7.2.290.0130.00316.62
7.2.250.0080.01115.04
7.2.240.0080.01315.02
7.2.230.0090.00815.01
7.2.220.0060.00615.11
7.2.210.0040.00815.12
7.2.200.0030.00915.05
7.2.190.0040.00814.92
7.2.180.0070.00714.96
7.2.170.0040.00915.02
7.2.60.0040.00816.80
7.2.00.0030.00619.51
7.1.330.0060.00715.57
7.1.320.0070.00715.69
7.1.310.0060.00715.73
7.1.300.0080.00415.72
7.1.290.0020.01215.65
7.1.280.0050.00715.64
7.1.270.0040.00915.78
7.1.260.0040.00915.75
7.1.200.0040.00815.85
7.1.100.0060.00618.13
7.1.70.0030.00717.16
7.1.60.0100.01619.13
7.1.50.0240.01034.87
7.1.00.0070.07322.33
7.0.200.0090.00316.82
7.0.100.0170.06320.00
7.0.90.0070.08319.99
7.0.80.0070.06719.90
7.0.70.0100.04319.88
7.0.60.0070.07020.09
7.0.50.0130.08320.26
7.0.40.0130.08020.11
7.0.30.0130.08020.08
7.0.20.0100.06320.19
7.0.10.0070.06720.04
7.0.00.0130.07320.06
5.6.280.0030.06320.82
5.6.250.0170.07020.47
5.6.240.0030.08320.68
5.6.230.0070.08320.50
5.6.220.0170.06720.52
5.6.210.0030.08720.63
5.6.200.0100.04721.04
5.6.190.0130.07021.10
5.6.180.0230.05720.93
5.6.170.0100.08021.16
5.6.160.0130.07721.03
5.6.150.0200.06720.92
5.6.140.0070.08321.09
5.6.130.0070.07721.07
5.6.120.0070.05321.03
5.6.110.0100.08320.98
5.6.100.0030.05320.92
5.6.90.0070.07321.03
5.6.80.0030.08320.33
5.6.70.0100.07320.42
5.6.60.0170.06720.30
5.6.50.0130.07020.33
5.6.40.0030.08020.53
5.6.30.0070.08720.29
5.6.20.0070.08020.30
5.6.10.0130.06320.41
5.6.00.0000.05320.44
5.5.380.0100.05720.45
5.5.370.0030.08320.45
5.5.360.0070.07320.50
5.5.350.0070.08320.37
5.5.340.0070.05020.77
5.5.330.0070.08320.90
5.5.320.0100.04020.83
5.5.310.0000.08020.89
5.5.300.0000.08320.88
5.5.290.0130.07320.82
5.5.280.0130.07720.92
5.5.270.0100.05720.79
5.5.260.0000.05720.90
5.5.250.0000.08720.73
5.5.240.0230.06320.28
5.5.230.0170.06320.11
5.5.220.0100.07020.30
5.5.210.0000.05020.16
5.5.200.0130.06720.22
5.5.190.0100.04720.23
5.5.180.0070.08320.21
5.5.160.0130.07020.14
5.5.150.0130.06320.16
5.5.140.0030.08020.12
5.5.130.0030.06320.25
5.5.120.0100.07019.98
5.5.110.0100.07020.20
5.5.100.0130.05020.03
5.5.90.0100.06320.06
5.5.80.0100.04720.06
5.5.70.0100.07019.99
5.5.60.0070.04319.92
5.5.50.0100.05320.07
5.5.40.0100.04320.05
5.5.30.0030.08320.08
5.5.20.0130.04020.13
5.5.10.0100.07320.05
5.5.00.0100.07320.10
5.4.450.0170.07019.37
5.4.440.0000.09019.37
5.4.430.0100.07019.55
5.4.420.0200.07719.41
5.4.410.0070.07719.29
5.4.400.0000.04718.88
5.4.390.0130.07319.03
5.4.380.0100.04319.09
5.4.370.0170.07019.05
5.4.360.0130.07019.03
5.4.350.0130.07719.04
5.4.340.0070.07319.04
5.4.320.0130.06319.12
5.4.310.0100.07318.88
5.4.300.0130.04718.89
5.4.290.0000.04718.90
5.4.280.0070.07719.13
5.4.270.0100.07319.13
5.4.260.0070.07319.20
5.4.250.0070.06719.04
5.4.240.0100.07319.22
5.4.230.0130.04319.04
5.4.220.0070.04718.84
5.4.210.0070.08018.86
5.4.200.0030.04718.81
5.4.190.0070.08019.13
5.4.180.0030.04719.09
5.4.170.0030.04719.02
5.4.160.0100.07018.92
5.4.150.0100.07018.85
5.4.140.0030.07716.45
5.4.130.0100.07016.41
5.4.120.0070.05716.24
5.4.110.0070.05716.42
5.4.100.0130.03016.43
5.4.90.0070.07016.34
5.4.80.0100.04016.31
5.4.70.0100.03716.41
5.4.60.0070.06316.36
5.4.50.0070.07716.32
5.4.40.0100.06016.45
5.4.30.0130.04316.49
5.4.20.0100.06316.31
5.4.10.0070.05316.45
5.4.00.0130.06015.91

preferences:
56.64 ms | 401 KiB | 5 Q