3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = array( array( 'category_id' => 1, 'children' => array( 'category_id' => 2, 'children' => array( 'category_id' => 3, ) ) ), array( 'category_id' => 4, 'children' => array( 'category_id' => 5, 'children' => array( 'category_id' => 6, ) ) ) ); $iterator = new RecursiveIteratorIterator( new RecursiveArrayIterator($array) ); for($iterator; $iterator->valid(); $iterator->next()) { printf( "Key: %s Value: %s Depth: %s\n", $iterator->key(), $iterator->current(), $iterator->getDepth() ); }

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.0150.00618.53
8.3.50.0140.00821.93
8.3.40.0060.00918.72
8.3.30.0120.00618.98
8.3.20.0070.00020.20
8.3.10.0060.00323.70
8.3.00.0050.00318.96
8.2.180.0000.01516.50
8.2.170.0110.00422.96
8.2.160.0070.00722.11
8.2.150.0060.00324.18
8.2.140.0040.00424.66
8.2.130.0000.00826.16
8.2.120.0080.00019.13
8.2.110.0070.00320.52
8.2.100.0080.00417.72
8.2.90.0000.00818.22
8.2.80.0000.00817.97
8.2.70.0090.00017.50
8.2.60.0030.00517.80
8.2.50.0030.00618.07
8.2.40.0000.00819.95
8.2.30.0080.00018.13
8.2.20.0050.00317.50
8.2.10.0000.00718.09
8.2.00.0040.00419.57
8.1.280.0140.00325.92
8.1.270.0040.00423.77
8.1.260.0040.00426.35
8.1.250.0020.00528.09
8.1.240.0070.01021.81
8.1.230.0060.00620.88
8.1.220.0050.00317.74
8.1.210.0090.00018.80
8.1.200.0030.00617.22
8.1.190.0060.00317.23
8.1.180.0030.00618.10
8.1.170.0070.00018.50
8.1.160.0030.00321.92
8.1.150.0080.00018.48
8.1.140.0000.00717.33
8.1.130.0030.00317.83
8.1.120.0030.00717.34
8.1.110.0030.00517.35
8.1.100.0050.00317.29
8.1.90.0000.00717.42
8.1.80.0030.00517.31
8.1.70.0030.00317.38
8.1.60.0040.00417.39
8.1.50.0030.00517.48
8.1.40.0040.00417.47
8.1.30.0060.00317.55
8.1.20.0040.00417.44
8.1.10.0080.00017.49
8.1.00.0040.00417.42
8.0.300.0000.00720.08
8.0.290.0070.00016.63
8.0.280.0000.00718.38
8.0.270.0030.00317.22
8.0.260.0030.00317.20
8.0.250.0030.00317.00
8.0.240.0000.00716.86
8.0.230.0040.00416.90
8.0.220.0030.00316.93
8.0.210.0060.00316.83
8.0.200.0000.00716.98
8.0.190.0040.00416.98
8.0.180.0000.00716.91
8.0.170.0020.00516.82
8.0.160.0030.00516.81
8.0.150.0040.00416.86
8.0.140.0030.00516.86
8.0.130.0050.00013.37
8.0.120.0000.00816.85
8.0.110.0030.00516.80
8.0.100.0040.00416.69
8.0.90.0050.00216.88
8.0.80.0040.01216.86
8.0.70.0020.00516.96
8.0.60.0000.00716.91
8.0.50.0040.00416.88
8.0.30.0130.01017.07
8.0.20.0110.00917.40
8.0.10.0050.00317.13
8.0.00.0100.00716.79
7.4.330.0030.00315.03
7.4.320.0000.00716.54
7.4.300.0030.00516.35
7.4.290.0060.00316.53
7.4.280.0080.00016.42
7.4.270.0040.00416.38
7.4.260.0070.00016.39
7.4.250.0000.00716.40
7.4.240.0020.00516.55
7.4.230.0000.00716.25
7.4.220.0170.00716.41
7.4.210.0110.00416.63
7.4.200.0050.00216.55
7.4.160.0130.01016.25
7.4.150.0100.00717.40
7.4.140.0130.00617.86
7.4.130.0100.00716.43
7.4.120.0060.01016.49
7.4.110.0130.00316.48
7.4.100.0060.01216.38
7.4.90.0080.00916.36
7.4.80.0060.01719.39
7.4.70.0030.01616.50
7.4.60.0110.00716.32
7.4.50.0000.00516.21
7.4.40.0140.00316.14
7.4.30.0030.01316.32
7.4.10.0110.00614.80
7.4.00.0050.01314.82
7.3.330.0050.00013.06
7.3.320.0000.00513.18
7.3.310.0030.00316.25
7.3.300.0000.00716.21
7.3.290.0090.00616.19
7.3.280.0080.01016.20
7.3.270.0090.01217.40
7.3.260.0130.00616.25
7.3.250.0120.00516.41
7.3.240.0100.00716.43
7.3.230.0090.00916.39
7.3.210.0110.00716.46
7.3.200.0080.00819.39
7.3.190.0030.01316.35
7.3.180.0030.01316.28
7.3.170.0070.01316.27
7.3.160.0090.00916.20
7.3.130.0030.01314.64
7.3.120.0060.01114.90
7.3.110.0080.00914.68
7.3.100.0060.00914.57
7.3.90.0060.00914.80
7.3.80.0050.00714.47
7.3.70.0040.00914.65
7.3.60.0060.00514.61
7.3.50.0050.01014.67
7.3.40.0060.00814.72
7.3.30.0050.00714.68
7.3.20.0050.00916.42
7.3.10.0040.01016.49
7.3.00.0060.00616.46
7.2.330.0060.00916.27
7.2.320.0110.00716.24
7.2.310.0150.00916.46
7.2.300.0120.00416.24
7.2.290.0130.01016.48
7.2.260.0130.00614.88
7.2.250.0090.01014.84
7.2.240.0040.01314.87
7.2.230.0060.01114.89
7.2.220.0060.00714.98
7.2.210.0030.01014.89
7.2.200.0050.00914.82
7.2.190.0040.00914.90
7.2.180.0050.01114.84
7.2.170.0040.01014.81
7.2.160.0030.01214.58
7.2.150.0000.00916.71
7.2.140.0070.00716.41
7.2.130.0050.00416.81
7.2.120.0080.00616.69
7.2.110.0120.00316.69
7.2.100.0060.00916.81
7.2.90.0020.01116.64
7.2.80.0080.00816.92
7.2.70.0060.01016.82
7.2.60.0070.00716.79
7.2.50.0000.00916.83
7.2.40.0050.00616.57
7.2.30.0040.00916.62
7.2.20.0040.01016.63
7.2.10.0100.00516.82
7.2.00.0050.01017.46
7.1.330.0090.00615.64
7.1.320.0070.00515.84
7.1.310.0070.00615.66
7.1.300.0050.00715.52
7.1.290.0050.00515.73
7.1.280.0040.00715.68
7.1.270.0080.00815.79
7.1.260.0080.00715.74
7.1.250.0030.00815.76
7.1.240.0070.01015.74
7.1.230.0070.00815.80
7.1.220.0030.01015.74
7.1.210.0000.01215.58
7.1.200.0050.00815.68
7.1.190.0110.00215.78
7.1.180.0060.00515.72
7.1.170.0070.00715.62
7.1.160.0050.00515.69
7.1.150.0050.00815.78
7.1.140.0000.01215.61
7.1.130.0030.01215.65
7.1.120.0040.00615.44
7.1.110.0020.01215.78
7.1.100.0020.01016.47
7.1.90.0050.00515.75
7.1.80.0050.00415.85
7.1.70.0020.00716.25
7.1.60.0040.01017.07
7.1.50.0080.00815.95
7.1.40.0030.00515.70
7.1.30.0010.00915.55
7.1.20.0030.00815.72
7.1.10.0060.00515.74
7.1.00.0030.03117.95
7.0.330.0070.00615.18
7.0.320.0040.00915.48
7.0.310.0060.00715.46
7.0.300.0040.00715.39
7.0.290.0040.00715.19
7.0.280.0030.01015.34
7.0.270.0080.00815.45
7.0.260.0030.00715.50
7.0.250.0110.00215.39
7.0.240.0030.01015.29
7.0.230.0090.00215.45
7.0.220.0030.01015.45
7.0.210.0030.00815.37
7.0.200.0040.00715.81
7.0.190.0070.00115.52
7.0.180.0040.00815.30
7.0.170.0020.01115.47
7.0.160.0050.00815.47
7.0.150.0070.00215.31
7.0.140.0050.02617.61
7.0.130.0060.00615.41
7.0.120.0020.01215.40
7.0.110.0070.00415.39
7.0.100.0050.00715.43
7.0.90.0030.00715.44
7.0.80.0050.00615.37
7.0.70.0050.00715.26
7.0.60.0070.03316.95
7.0.50.0080.02016.24
7.0.40.0090.02915.70
7.0.30.0110.02615.71
7.0.20.0160.02815.69
7.0.10.0060.02315.58
7.0.00.0040.02915.74
5.6.400.0060.00314.47
5.6.390.0100.00714.53
5.6.380.0050.01014.31
5.6.370.0080.00514.35
5.6.360.0090.00714.31
5.6.350.0030.01014.18
5.6.340.0060.00514.29
5.6.330.0050.00914.15
5.6.320.0030.01014.42
5.6.310.0030.01014.63
5.6.300.0090.00314.15
5.6.290.0030.00914.57
5.6.280.0040.03016.44
5.6.270.0020.01214.18
5.6.260.0030.01014.36
5.6.250.0050.00814.39
5.6.240.0040.01114.26
5.6.230.0000.01214.27
5.6.220.0070.00514.54
5.6.210.0110.02816.34
5.6.200.0080.03115.60
5.6.190.0060.02516.39
5.6.180.0080.02616.43
5.6.170.0070.02316.45
5.6.160.0050.03416.27
5.6.150.0090.02815.70
5.6.140.0060.03215.57
5.6.130.0080.03015.64
5.6.120.0050.02316.60
5.6.110.0090.03316.66
5.6.100.0060.02216.55
5.6.90.0090.03216.69
5.6.80.0060.03216.32
5.6.70.1550.01716.33
5.6.60.0070.00514.32
5.6.50.0090.00714.12
5.6.40.0050.00814.08
5.6.30.0080.00714.34
5.6.20.0030.01114.51
5.6.10.0030.00814.23
5.6.00.0090.00514.24
5.5.380.0110.00212.65
5.5.370.0070.00512.54
5.5.360.0040.00812.69
5.5.350.0040.02315.16
5.5.340.0070.02914.38
5.5.330.0050.02015.21
5.5.320.0140.02615.16
5.5.310.0120.03415.13
5.5.300.0100.02614.45
5.5.290.0050.03314.33
5.5.280.0080.01615.44
5.5.270.0030.03415.34
5.5.260.0050.01715.20
5.5.250.0050.02915.33
5.5.240.0130.02815.09
5.5.230.0030.00712.52
5.5.220.0020.00712.55
5.5.210.0060.00612.36
5.5.200.0070.00512.60
5.5.190.0060.00612.56
5.5.180.0030.00812.41
5.5.170.0030.01012.65
5.5.160.0060.00512.73
5.5.150.0030.00912.40
5.5.140.0030.00912.51
5.5.130.0060.00812.51
5.5.120.0050.00512.68
5.5.110.0030.00712.45
5.5.100.0020.00812.50
5.5.90.0060.00512.65
5.5.80.0030.00712.59
5.5.70.0020.01112.51
5.5.60.0030.00612.44
5.5.50.0080.00512.45
5.5.40.0040.01012.68
5.5.30.0060.00612.50
5.5.20.0050.00912.61
5.5.10.0130.00212.41
5.5.00.0080.00612.57
5.4.450.0340.02713.94
5.4.440.0140.02613.90
5.4.430.0330.02413.85
5.4.420.0270.00413.92
5.4.410.0080.02313.69
5.4.400.0170.02613.61
5.4.390.0110.02413.39
5.4.380.0130.02713.49
5.4.370.0070.01413.61
5.4.360.0070.01913.53
5.4.350.0050.02611.27
5.4.340.0080.01611.33
5.4.330.0050.00510.79
5.4.320.0050.01711.38
5.4.310.0070.01511.50
5.4.300.0030.01711.54
5.4.290.0060.01711.48
5.4.280.0070.01411.43
5.4.270.0040.01511.39
5.4.260.0050.01511.42
5.4.250.0050.01611.42
5.4.240.0020.01611.40
5.4.230.0050.01711.50
5.4.220.0050.01511.46
5.4.210.0050.01511.36
5.4.200.0050.01611.42
5.4.190.0070.01811.41
5.4.180.0050.01511.53
5.4.170.0060.01611.48
5.4.160.0060.01511.50
5.4.150.0030.01811.50
5.4.140.0060.01711.32
5.4.130.0070.01511.40
5.4.120.0060.01711.34
5.4.110.0040.01711.25
5.4.100.0040.01511.31
5.4.90.0060.01611.25
5.4.80.0080.01211.25
5.4.70.0040.01711.25
5.4.60.0030.02111.34
5.4.50.0040.01511.31
5.4.40.0030.01511.37
5.4.30.0040.01711.36
5.4.20.0050.01411.29
5.4.10.0020.01711.23
5.4.00.0040.01511.15
5.3.290.0050.01811.42
5.3.280.0050.01711.33
5.3.270.0050.01711.35
5.3.260.0040.01711.43
5.3.250.0070.01611.41
5.3.240.0040.01811.40
5.3.230.0040.01611.38
5.3.220.0060.01411.38
5.3.210.0070.01511.34
5.3.200.0040.01811.38
5.3.190.0060.01511.38
5.3.180.0030.01811.43
5.3.170.0050.01411.45
5.3.160.0040.01611.44
5.3.150.0060.01611.44
5.3.140.0040.01811.36
5.3.130.0060.01611.45
5.3.120.0040.01911.41
5.3.110.0030.01711.39
5.3.100.0020.01811.24
5.3.90.0040.01611.24
5.3.80.0040.02111.17
5.3.70.0060.01711.20
5.3.60.0060.01611.22
5.3.50.0050.02011.14
5.3.40.0060.01711.20
5.3.30.0060.01411.21
5.3.20.0040.01511.07
5.3.10.0070.01511.01
5.3.00.0070.01411.01
5.2.170.0050.0189.31
5.2.160.0050.0169.30
5.2.150.0050.0189.22
5.2.140.0030.0209.33
5.2.130.0030.0179.20
5.2.120.0050.0179.34
5.2.110.0060.0209.33
5.2.100.0050.0179.18
5.2.90.0040.0169.28
5.2.80.0040.0189.24
5.2.70.0040.0179.23
5.2.60.0040.0169.21
5.2.50.0020.0209.14
5.2.40.0030.0179.22
5.2.30.0050.0159.13
5.2.20.0060.0169.09
5.2.10.0020.0199.04
5.2.00.0020.0228.99
5.1.60.0050.0128.31
5.1.50.0020.0178.36
5.1.40.0020.0168.30
5.1.30.0040.0148.60
5.1.20.0020.0168.48
5.1.10.0030.0178.38
5.1.00.0040.0158.35
5.0.50.0060.0117.58
5.0.40.0020.0137.51
5.0.30.0020.0187.42
5.0.20.0020.0127.40
5.0.10.0050.0097.39
5.0.00.0020.0187.39
4.4.90.0040.0096.66
4.4.80.0020.0126.65
4.4.70.0010.0106.65
4.4.60.0050.0106.65
4.4.50.0020.0106.66
4.4.40.0040.0146.63
4.4.30.0040.0076.65
4.4.20.0020.0116.69
4.4.10.0020.0096.69
4.4.00.0020.0166.65
4.3.110.0030.0106.60
4.3.100.0020.0106.60
4.3.90.0010.0106.59
4.3.80.0020.0156.56
4.3.70.0020.0096.59
4.3.60.0030.0096.58
4.3.50.0040.0096.58
4.3.40.0050.0146.54
4.3.30.0050.0075.91
4.3.20.0010.0095.90
4.3.10.0010.0105.88
4.3.00.0110.0137.55

preferences:
36.88 ms | 401 KiB | 5 Q