3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = ['red', 'green', 'blue']; $choices = []; foreach ($e => $a) { $choices[$a] = $a; } var_dump($choices); var_dump(array_combine($a, $a));

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)
5.4.390.0130.06018.79
5.4.380.0130.06318.44
5.4.370.0300.04318.74
5.4.360.0230.04718.62
5.4.350.0170.05318.62
5.4.340.0100.06318.61
5.4.320.0270.05018.83
5.4.310.0100.06318.52
5.4.300.0270.04718.61
5.4.290.0130.06018.53
5.4.280.0170.05718.46
5.4.270.0270.04718.75
5.4.260.0130.05718.68
5.4.250.0200.06318.50
5.4.240.0200.05018.46
5.4.230.0370.04718.77
5.4.220.0170.06718.54
5.4.210.0130.06318.78
5.4.200.0270.05016.62
5.4.190.0230.04318.54
5.4.180.0230.04718.73
5.4.170.0230.06318.51
5.4.160.0200.05018.48
5.4.150.0130.06018.48
5.4.140.0200.05316.21
5.4.130.0070.06016.26
5.4.120.0270.04016.33
5.4.110.0100.06016.22
5.4.100.0200.04716.44
5.4.90.0170.05016.25
5.4.80.0070.05316.29
5.4.70.0070.06016.39
5.4.60.0070.05716.23
5.4.50.0200.04716.39
5.4.40.0200.05016.20
5.4.30.0200.04716.27
5.4.20.0170.05316.24
5.4.10.0270.04716.22
5.4.00.0100.05315.68
5.3.290.0230.04714.56
5.3.280.0130.06014.69
5.3.270.0230.07314.52
5.3.260.0200.05314.61
5.3.250.0230.05014.52
5.3.240.0170.05314.58
5.3.230.0100.06014.61
5.3.220.0230.04714.66
5.3.210.0100.06714.48
5.3.200.0270.05014.65
5.3.190.0270.04014.67
5.3.180.0170.05014.47
5.3.170.0300.05314.51
5.3.160.0230.04714.55
5.3.150.0230.04714.46
5.3.140.0100.06014.50
5.3.130.0270.04314.45
5.3.120.0170.05314.54
5.3.110.0200.05714.57
5.3.100.0130.06714.11
5.3.90.0200.05313.97
5.3.80.0230.05714.00
5.3.70.0130.06014.09
5.3.60.0270.04014.07
5.3.50.0270.04314.04
5.3.40.0270.04013.89
5.3.30.0170.05713.94
5.3.20.0170.05013.78
5.3.10.0130.05713.73
5.3.00.0200.04713.71
5.2.170.0130.04011.20
5.2.160.0200.03311.07
5.2.150.0200.03311.30
5.2.140.0100.05011.13
5.2.130.0130.04011.25
5.2.120.0070.04311.23
5.2.110.0130.04011.05
5.2.100.0070.04711.09
5.2.90.0200.03711.06
5.2.80.0200.03711.13
5.2.70.0070.05011.25
5.2.60.0130.04311.08
5.2.50.0200.03311.05
5.2.40.0030.04710.95
5.2.30.0200.04710.97
5.2.20.0100.04010.99
5.2.10.0130.03710.92
5.2.00.0100.04710.72
5.1.60.0130.03310.11
5.1.50.0100.04010.01
5.1.40.0200.0339.98
5.1.30.0170.03310.39
5.1.20.0330.03310.34
5.1.10.0130.03310.08
5.1.00.0170.03010.10
5.0.50.0130.0238.58
5.0.40.0100.0238.42
5.0.30.0070.0478.21
5.0.20.0100.0308.28
5.0.10.0070.0278.18
5.0.00.0130.0408.35
4.4.90.0070.0205.95
4.4.80.0100.0205.87
4.4.70.0070.0235.89
4.4.60.0030.0335.91
4.4.50.0030.0235.88
4.4.40.0070.0375.82
4.4.30.0000.0275.92
4.4.20.0030.0235.95
4.4.10.0100.0205.94
4.4.00.0030.0375.90
4.3.110.0100.0205.80
4.3.100.0030.0235.74
4.3.90.0000.0275.77
4.3.80.0030.0375.91
4.3.70.0100.0205.77
4.3.60.0030.0235.78
4.3.50.0130.0235.82
4.3.40.0030.0375.86
4.3.30.0100.0134.61
4.3.20.0030.0234.62
4.3.10.0000.0274.61
4.3.00.0070.0179.46

preferences:
146.24 ms | 1394 KiB | 7 Q