3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr = array( 20 => array( 'width' => 20, 'height' => 20, ), 60 => array( 'width' => 60, 'height' => 40, ), 150 => array( 'width' => 150, 'height' => 300, ) ); $it = new RecursiveArrayIterator( $arr ); while( $it->valid() ) { echo $it -> key() . ' : ' . $it -> current() .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.40.0070.01518.67
8.3.30.0080.01118.46
8.3.20.0070.00418.65
8.3.10.0040.00820.60
8.3.00.0050.00519.38
8.2.170.0130.00322.96
8.2.160.0120.00920.27
8.2.150.0060.00324.18
8.2.140.0090.00024.66
8.2.130.0050.00526.16
8.2.120.0040.00421.13
8.2.110.0030.00621.97
8.2.100.0110.00317.91
8.2.90.0060.00319.27
8.2.80.0000.00917.97
8.2.70.0040.00417.50
8.2.60.0000.00917.68
8.2.50.0000.00818.10
8.2.40.0030.00618.28
8.2.30.0000.00718.05
8.2.20.0080.00319.51
8.2.10.0120.00617.75
8.2.00.0040.00417.80
8.1.270.0030.00624.66
8.1.260.0070.00326.35
8.1.250.0060.00328.09
8.1.240.0080.00422.21
8.1.230.0030.01017.70
8.1.220.0060.00317.91
8.1.210.0000.00918.77
8.1.200.0030.00617.23
8.1.190.0030.00617.23
8.1.180.0080.00018.10
8.1.170.0030.01018.82
8.1.160.0040.00418.94
8.1.150.0030.00618.75
8.1.140.0000.00817.57
8.1.130.0070.00017.89
8.1.120.0030.00617.43
8.1.110.0040.00417.52
8.1.100.0000.00717.43
8.1.90.0090.00017.52
8.1.80.0060.00317.57
8.1.70.0050.00317.41
8.1.60.0030.00617.55
8.1.50.0030.00517.54
8.1.40.0060.00317.64
8.1.30.0080.00017.67
8.1.20.0050.00317.52
8.1.10.0000.00917.66
8.1.00.0050.00517.57
8.0.300.0000.00920.50
8.0.290.0030.00816.63
8.0.280.0000.00818.27
8.0.270.0040.00417.24
8.0.260.0000.00716.87
8.0.250.0000.00916.96
8.0.240.0040.00416.98
8.0.230.0090.00016.82
8.0.220.0040.00416.86
8.0.210.0070.00016.82
8.0.200.0000.00816.95
8.0.190.0030.00616.87
8.0.180.0000.00816.81
8.0.170.0090.00016.75
8.0.160.0040.00416.86
8.0.150.0070.00316.77
8.0.140.0060.00316.88
8.0.130.0040.00413.31
8.0.120.0000.00816.93
8.0.110.0030.00516.84
8.0.100.0050.00316.88
8.0.90.0030.00616.69
8.0.80.0070.01316.79
8.0.70.0040.00416.90
8.0.60.0000.00916.89
8.0.50.0040.00416.73
8.0.30.0350.03617.16
8.0.20.0310.01616.88
8.0.10.0040.00416.90
8.0.00.0350.01616.49
7.4.330.0060.00013.02
7.4.320.0030.00516.49
7.4.300.0000.00716.30
7.4.290.0080.00016.40
7.4.280.0000.00916.30
7.4.270.0030.00516.44
7.4.260.0030.00613.26
7.4.250.0000.01116.50
7.4.240.0000.00816.32
7.4.230.0050.00216.28
7.4.220.0140.00716.17
7.4.210.0080.01116.29
7.4.200.0050.00316.40
7.4.190.0090.00016.29
7.4.160.0000.03216.43
7.4.150.0070.01416.33
7.4.140.0120.01216.42
7.4.130.0290.01016.46
7.4.120.0270.00616.41
7.4.110.0130.02116.34
7.4.100.1500.03516.38
7.4.90.0400.01716.38
7.4.80.0300.01619.39
7.4.70.0610.01016.42
7.4.60.0100.01316.37
7.4.50.0280.00716.39
7.4.40.0100.00716.45
7.4.30.0290.01116.35
7.4.00.0030.01314.97
7.3.330.0100.00013.14
7.3.320.0040.00413.17
7.3.310.0050.00316.29
7.3.300.0040.00416.13
7.3.290.0060.01616.15
7.3.280.0140.01216.23
7.3.270.0300.02316.31
7.3.260.0230.01216.16
7.3.250.0160.01716.26
7.3.240.0100.01415.99
7.3.230.0140.01116.25
7.3.210.0170.01416.43
7.3.200.0160.02816.28
7.3.190.0300.01516.39
7.3.180.0140.01116.16
7.3.170.1020.03416.18
7.3.160.0330.01016.52
7.3.120.0120.00914.72
7.2.330.0580.03816.39
7.2.320.0770.02516.63
7.2.310.0390.02116.21
7.2.300.0110.01116.36
7.2.290.0350.01616.55
7.2.00.0030.01219.48
7.1.70.0020.00516.54
7.1.60.0180.01119.40
7.1.50.0230.00834.68
7.1.00.0030.03322.39
7.0.200.0100.00714.96
7.0.140.0100.06322.00
7.0.120.0030.07722.18
7.0.100.0200.07019.93
7.0.90.0100.08019.92
7.0.80.0130.08319.81
7.0.70.0100.08019.84
7.0.60.0170.07019.86
7.0.50.0030.08320.34
7.0.40.0200.07320.04
7.0.30.0100.08320.07
7.0.20.0100.05019.99
7.0.10.0100.08320.04
7.0.00.0070.07020.14
5.6.280.0100.07021.10
5.6.250.0170.06720.59
5.6.240.0130.08020.59
5.6.230.0170.07320.60
5.6.220.0000.08320.65
5.6.210.0170.07320.54
5.6.200.0100.08021.04
5.6.190.0100.08321.10
5.6.180.0170.07721.04
5.6.170.0070.08021.14
5.6.160.0170.04721.02
5.6.150.0030.07721.13
5.6.140.0100.07721.02
5.6.130.0030.09721.11
5.6.120.0070.05721.05
5.6.110.0070.04321.00
5.6.100.0100.08721.00
5.6.90.0030.06020.93
5.6.80.0100.05320.43
5.6.70.0070.04020.46
5.6.60.0000.06720.37
5.6.50.0130.06320.49
5.6.40.0030.06720.43
5.6.30.0000.09320.46
5.6.20.0130.06020.48
5.6.10.0170.03320.30
5.6.00.0070.05720.35
5.5.380.0100.08320.34
5.5.370.0170.07020.48
5.5.360.0030.09020.41
5.5.350.0030.07720.41
5.5.340.0100.08020.81
5.5.330.0130.06320.91
5.5.320.0030.06320.79
5.5.310.0130.06720.87
5.5.300.0170.08320.88
5.5.290.0030.09320.86
5.5.280.0070.06320.80
5.5.270.0100.08720.81
5.5.260.0030.07720.77
5.5.250.0170.07720.64
5.5.240.0100.05720.15
5.5.230.0070.04320.29
5.5.220.0070.06320.30
5.5.210.0030.06320.27
5.5.200.0170.06720.18
5.5.190.0100.06720.15
5.5.180.0100.06020.18
5.5.160.0200.05320.24
5.5.150.0100.06320.26
5.5.140.0230.06320.14
5.5.130.0130.07020.14
5.5.120.0130.08020.18
5.5.110.0100.07020.26
5.5.100.0170.08020.07
5.5.90.0130.05720.06
5.5.80.0030.06320.11
5.5.70.0130.06720.06
5.5.60.0000.04720.05
5.5.50.0000.08020.05
5.5.40.0070.05720.08
5.5.30.0100.06720.14
5.5.20.0070.06720.11
5.5.10.0070.07720.05
5.5.00.0100.07019.99
5.4.450.0130.04319.31
5.4.440.0100.06019.21
5.4.430.0130.07019.34
5.4.420.0130.07019.38
5.4.410.0100.07019.07
5.4.400.0000.04318.83
5.4.390.0100.04718.86
5.4.380.0130.07018.96
5.4.370.0200.07318.76
5.4.360.0100.09019.03
5.4.350.0200.06718.98
5.4.340.0100.06318.88
5.4.320.0030.08319.05
5.4.310.0100.07318.98
5.4.300.0130.06318.89
5.4.290.0130.07318.88
5.4.280.0100.06318.75
5.4.270.0100.08019.08
5.4.260.0200.04018.93
5.4.250.0100.06318.88
5.4.240.0100.05318.71
5.4.230.0070.06018.88
5.4.220.0070.06018.71
5.4.210.0170.06718.70
5.4.200.0100.05718.93
5.4.190.0030.08718.95
5.4.180.0070.07718.87
5.4.170.0100.07718.81
5.4.160.0100.05018.91
5.4.150.0200.07319.06
5.4.140.0100.03316.17
5.4.130.0100.07016.26
5.4.120.0000.08016.26
5.4.110.0100.07016.24
5.4.100.0170.06716.23
5.4.90.0070.07716.42
5.4.80.0070.06716.23
5.4.70.0070.07716.13
5.4.60.0030.06716.30
5.4.50.0000.08016.11
5.4.40.0070.07716.11
5.4.30.0070.04716.22
5.4.20.0170.07016.16
5.4.10.0100.06316.27
5.4.00.0100.04015.79
5.3.290.0130.07714.41
5.3.280.0000.06714.41
5.3.270.0100.08014.38
5.3.260.0100.07014.30
5.3.250.0030.08314.30
5.3.240.0100.06714.45
5.3.230.0030.08314.33
5.3.220.0170.07714.33
5.3.210.0170.05714.30
5.3.200.0170.06714.36
5.3.190.0070.07014.41
5.3.180.0130.04714.40
5.3.170.0100.08014.38
5.3.160.0130.04314.39
5.3.150.0100.09014.33
5.3.140.0070.06014.39
5.3.130.0130.07314.39
5.3.120.0100.07014.37
5.3.110.0130.07014.38
5.3.100.0100.08014.30
5.3.90.0070.04714.30
5.3.80.0100.07314.30
5.3.70.0070.05714.30
5.3.60.0170.07314.30
5.3.50.0230.06314.30
5.3.40.0200.07014.30
5.3.30.0170.07014.30
5.3.20.0070.04714.30
5.3.10.0130.06314.30
5.3.00.0170.06714.30
5.2.170.0170.05714.30
5.2.160.0130.06014.30
5.2.150.0100.04014.30
5.2.140.0100.06314.30
5.2.130.0100.06014.30
5.2.120.0100.06014.30
5.2.110.0100.04314.30
5.2.100.0070.05014.30
5.2.90.0130.03014.30
5.2.80.0100.07014.30
5.2.70.0200.06014.30
5.2.60.0070.06314.30
5.2.50.0130.05314.30
5.2.40.0100.06714.30
5.2.30.0100.05714.30
5.2.20.0130.06014.30
5.2.10.0170.05014.30
5.2.00.0130.06314.30
5.1.60.0070.06014.30
5.1.50.0070.05714.30
5.1.40.0100.04314.30
5.1.30.0000.03714.30
5.1.20.0130.05314.30
5.1.10.0070.04014.30
5.1.00.0070.05014.30
5.0.50.0030.04314.30
5.0.40.0070.03314.30
5.0.30.0100.03014.30
5.0.20.0030.02314.30
5.0.10.0000.04714.30
5.0.00.0030.06714.30
4.4.90.0030.03314.30
4.4.80.0000.02314.30
4.4.70.0030.03014.30
4.4.60.0070.01714.30
4.4.50.0030.03314.30
4.4.40.0030.05314.30
4.4.30.0030.02714.30
4.4.20.0000.04014.30
4.4.10.0000.03714.30
4.4.00.0030.05314.30
4.3.110.0000.02014.30
4.3.100.0030.02014.30
4.3.90.0000.03714.30
4.3.80.0030.04014.30
4.3.70.0030.02314.30
4.3.60.0070.03014.30
4.3.50.0070.03014.30
4.3.40.0000.03014.30
4.3.30.0000.03714.30
4.3.20.0000.03714.30
4.3.10.0070.02014.30
4.3.00.0000.03714.30

preferences:
49.06 ms | 400 KiB | 5 Q