3v4l.org

run code in 300+ PHP versions simultaneously
<?php function MyArray() { return array('de'=>array('eins','zwei','drei')); } // based on feature request for PHP3, nine years ago, per https://bugs.php.net/bug.php?id=2341 // bug refiled from version 3 to version 4 // but Sterling Hughes felt the 'WTF' factor was too high to have it fixed // now should work in PHP5.5 $arr1DE=myArray()['de']; $arr2DE=array('de'=>array('eins','zwei','drei'))['de']; var_dump($arr1DE, $arr2DE);

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.0140.00718.55
8.3.50.0120.00821.99
8.3.40.0040.01118.72
8.3.30.0100.00618.86
8.3.20.0040.00418.73
8.3.10.0000.00719.30
8.3.00.0000.00723.61
8.2.180.0180.00716.75
8.2.170.0060.00922.96
8.2.160.0100.00620.43
8.2.150.0040.00424.18
8.2.140.0080.00024.66
8.2.130.0050.00326.16
8.2.120.0000.00720.91
8.2.110.0070.00320.57
8.2.100.0000.01117.91
8.2.90.0000.00819.27
8.2.80.0030.00617.97
8.2.70.0030.00917.50
8.2.60.0040.00417.91
8.2.50.0000.00818.07
8.2.40.0040.00418.09
8.2.30.0040.00418.06
8.2.20.0000.00717.59
8.2.10.0040.00417.80
8.2.00.0040.00417.80
8.1.280.0070.00725.92
8.1.270.0050.00323.99
8.1.260.0140.00326.35
8.1.250.0040.00428.09
8.1.240.0090.00022.55
8.1.230.0060.00620.84
8.1.220.0000.00818.77
8.1.210.0000.00818.96
8.1.200.0000.00817.10
8.1.190.0040.00417.41
8.1.180.0050.00318.10
8.1.170.0030.00618.59
8.1.160.0000.00718.82
8.1.150.0000.00818.57
8.1.140.0070.00017.26
8.1.130.0030.00317.82
8.1.120.0070.00017.38
8.1.110.0040.00417.35
8.1.100.0040.00417.40
8.1.90.0000.00717.40
8.1.80.0070.00017.44
8.1.70.0000.00717.36
8.1.60.0000.00817.48
8.1.50.0020.00517.37
8.1.40.0030.00617.41
8.1.30.0040.00417.70
8.1.20.0030.00617.65
8.1.10.0000.01017.53
8.1.00.0050.00217.33
8.0.300.0040.00419.85
8.0.290.0040.00417.18
8.0.280.0030.00318.30
8.0.270.0000.00717.18
8.0.260.0030.00516.82
8.0.250.0040.00416.84
8.0.240.0050.00516.99
8.0.230.0000.00716.97
8.0.220.0000.00716.80
8.0.210.0030.00316.91
8.0.200.0060.00016.82
8.0.190.0050.00316.96
8.0.180.0030.00616.88
8.0.170.0050.00316.94
8.0.160.0000.00716.99
8.0.150.0030.00616.82
8.0.140.0040.00416.84
8.0.130.0030.00313.29
8.0.120.0040.00416.91
8.0.110.0040.00416.67
8.0.100.0040.00416.77
8.0.90.0040.00416.75
8.0.80.0150.00016.87
8.0.70.0000.00716.69
8.0.60.0070.00016.95
8.0.50.0000.00716.71
8.0.30.0040.01817.15
8.0.20.0100.01217.40
8.0.10.0000.00816.86
8.0.00.0140.00816.67
7.4.330.0000.00514.64
7.4.320.0050.00316.44
7.4.300.0040.00416.52
7.4.290.0000.00716.61
7.4.280.0000.00716.57
7.4.270.0030.00316.59
7.4.260.0030.00313.25
7.4.250.0090.00016.50
7.4.240.0070.00016.43
7.4.230.0030.00316.50
7.4.220.0070.01016.64
7.4.210.0080.00816.49
7.4.200.0040.00416.39
7.4.190.0050.00216.60
7.4.160.0100.00716.49
7.4.150.0170.00017.40
7.4.140.0090.01117.86
7.4.130.0120.00816.52
7.4.120.0090.01316.46
7.4.110.0040.01716.59
7.4.100.0080.00816.45
7.4.90.0030.01416.54
7.4.80.0200.00319.37
7.4.70.0120.00616.45
7.4.60.0040.01316.46
7.4.50.0030.00616.55
7.4.40.0030.01422.52
7.4.30.0120.00916.52
7.4.00.0100.00314.80
7.3.330.0050.00013.16
7.3.320.0000.00513.05
7.3.310.0030.00316.35
7.3.300.0070.00016.25
7.3.290.0100.00916.33
7.3.280.0060.00816.32
7.3.270.0140.01217.40
7.3.260.0110.01318.24
7.3.250.0110.00616.38
7.3.240.0180.00616.28
7.3.230.0110.00716.39
7.3.210.0120.01216.34
7.3.200.0070.01419.39
7.3.190.0090.00916.54
7.3.180.0060.00916.24
7.3.170.0080.00816.61
7.3.160.0130.00716.32
7.3.120.0030.01414.73
7.2.330.0060.01116.33
7.2.320.0050.01416.63
7.2.310.0200.00316.70
7.2.300.0100.00616.76
7.2.290.0030.01316.43
7.2.00.0080.00419.24
7.1.100.0060.00618.14
7.1.70.0030.00517.25
7.1.60.0040.00719.40
7.1.50.0070.01716.94
7.1.00.0100.06722.27
7.0.200.0050.00316.84
7.0.140.0000.07722.00
7.0.70.0000.03321.66
7.0.60.0000.03721.70
7.0.50.0000.06022.09
7.0.40.0100.07720.14
7.0.30.0070.05719.99
7.0.20.0030.08720.13
7.0.10.0100.06019.98
7.0.00.0000.08320.09
5.6.280.0030.07721.09
5.6.220.0000.04020.56
5.6.210.0070.03320.44
5.6.200.0000.05720.95
5.6.190.0030.08321.03
5.6.180.0070.08021.16
5.6.170.0000.08320.94
5.6.160.0100.08021.02
5.6.150.0030.07720.98
5.6.140.0070.07021.03
5.6.130.0070.08021.11
5.6.120.0030.08721.02
5.6.110.0100.07721.08
5.6.100.0100.07321.06
5.6.90.0030.08721.03
5.6.80.0000.04320.38
5.6.70.0100.06720.48
5.6.60.0000.06320.42
5.6.50.0000.07720.55
5.6.40.0000.08320.29
5.6.30.0030.05720.30
5.6.20.0130.06720.32
5.6.10.0030.06720.29
5.6.00.0030.08320.50
5.5.360.0030.04320.31
5.5.350.0030.04720.32
5.5.340.0030.04020.90
5.5.330.0030.08020.79
5.5.320.0030.08320.89
5.5.310.0230.06720.91
5.5.300.0100.07720.59
5.5.290.0030.08020.91
5.5.280.0030.08020.81
5.5.270.0070.07720.84
5.5.260.0130.08020.88
5.5.250.0130.07320.64
5.5.240.0000.08720.24
5.5.230.0030.08020.13
5.5.220.0100.06020.16
5.5.210.0030.08020.14
5.5.200.0000.07320.07
5.5.190.0030.07720.21
5.5.180.0130.07020.25
5.5.160.0030.08019.94
5.5.150.0100.07720.24
5.5.140.0070.05320.09
5.5.130.0000.08320.16
5.5.120.0000.05720.20
5.5.110.0070.07720.09
5.5.100.0070.06320.04
5.5.90.0070.07020.11
5.5.80.0070.07020.13
5.5.70.0130.07020.10
5.5.60.0070.05020.07
5.5.50.0070.07320.14
5.5.40.0030.07320.12
5.5.30.0070.06020.12
5.5.20.0030.08320.07
5.5.10.0030.07319.93
5.5.00.0070.04020.11
5.4.450.0030.05719.54
5.4.440.0100.07019.36
5.4.430.0100.07019.18
5.4.420.0100.07719.46
5.4.410.0100.07019.30
5.4.400.0070.06019.13
5.4.390.0070.07719.08
5.4.380.0000.07718.89
5.4.370.0000.08019.15
5.4.360.0100.05319.21
5.4.350.0070.06719.11
5.4.340.0070.07719.11
5.4.320.0000.08019.13
5.4.310.0000.06319.03
5.4.300.0000.08319.19
5.4.290.0070.05719.20
5.4.280.0070.06319.17
5.4.270.0100.06719.19
5.4.260.0030.07719.12
5.4.250.0070.07019.16
5.4.240.0070.07019.13
5.4.230.0000.07319.12
5.4.220.0000.08719.01
5.4.210.0100.06018.88
5.4.200.0070.07319.12
5.4.190.0070.06719.09
5.4.180.0000.07719.10
5.4.170.0030.05719.14
5.4.160.0030.07319.00
5.4.150.0030.04719.02
5.4.140.0030.07316.36
5.4.130.0030.07316.39
5.4.120.0000.05016.14
5.4.110.0070.05716.49
5.4.100.0070.06316.49
5.4.90.0030.06016.26
5.4.80.0030.07016.32
5.4.70.0000.07016.30
5.4.60.0030.07716.45
5.4.50.0030.07716.31
5.4.40.0000.07316.40
5.4.30.0070.06716.35
5.4.20.0100.06316.32
5.4.10.0030.05016.39
5.4.00.0000.07315.79
5.3.290.0030.07014.64
5.3.280.0070.07714.57
5.3.270.0030.05314.66
5.3.260.0030.07714.70
5.3.250.0070.06314.66
5.3.240.0070.06714.66
5.3.230.0000.04714.66
5.3.220.0000.06014.57
5.3.210.0030.06014.63
5.3.200.0030.04714.58
5.3.190.0000.08014.60
5.3.180.0000.07314.53
5.3.170.0000.07714.54
5.3.160.0100.06714.53
5.3.150.0000.06014.48
5.3.140.0070.07714.54
5.3.130.0030.07014.54
5.3.120.0070.06014.63
5.3.110.0030.08014.50
5.3.100.0000.05013.96
5.3.90.0000.07314.11
5.3.80.0070.06314.03
5.3.70.0000.07013.95
5.3.60.0070.04714.13
5.3.50.0070.07013.88
5.3.40.0070.06713.87
5.3.30.0000.07713.93
5.3.20.0000.07313.78
5.3.10.0030.06713.68
5.3.00.0000.07013.68
5.2.170.0000.06712.52
5.2.160.0070.05712.52
5.2.150.0000.06712.52
5.2.140.0000.05712.52
5.2.130.0000.04712.52
5.2.120.0000.05312.52
5.2.110.0030.06012.52
5.2.100.0000.06712.52
5.2.90.0000.05712.52
5.2.80.0030.06312.52
5.2.70.0030.06312.52
5.2.60.0030.06012.52
5.2.50.0000.06312.52
5.2.40.0000.06312.52
5.2.30.0030.06312.52
5.2.20.0000.06312.52
5.2.10.0030.05012.52
5.2.00.0070.05012.52
5.1.60.0000.05312.52
5.1.50.0030.05312.52
5.1.40.0030.04012.52
5.1.30.0030.03712.52
5.1.20.0030.04712.52
5.1.10.0070.05012.52
5.1.00.0030.04312.52
5.0.50.0070.02312.52
5.0.40.0000.04312.52
5.0.30.0030.06312.52
5.0.20.0030.03712.52
5.0.10.0000.04712.52
5.0.00.0030.06712.52
4.4.90.0070.03012.52
4.4.80.0030.03012.52
4.4.70.0000.02012.52
4.4.60.0030.03712.52
4.4.50.0000.03712.52
4.4.40.0000.05012.52
4.4.30.0000.03312.52
4.4.20.0030.02712.52
4.4.10.0000.02712.52
4.4.00.0030.04012.52
4.3.110.0030.02712.52
4.3.100.0030.02712.52
4.3.90.0000.03012.52
4.3.80.0000.05312.52
4.3.70.0000.03712.52
4.3.60.0000.03012.52
4.3.50.0000.02712.52
4.3.40.0000.05312.52
4.3.30.0000.04012.52
4.3.20.0000.03012.52
4.3.10.0030.02312.52
4.3.00.0000.02312.52

preferences:
47.48 ms | 401 KiB | 5 Q