3v4l.org

run code in 300+ PHP versions simultaneously
<?php $foo = array('foobar'); $attributes = array('class' => 'control-label'); if ($foo) { echo '1'; $attributes = array_merge($foo, $attributes); } var_dump($attributes);

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.0100.01018.84
8.3.30.0140.00718.96
8.3.20.0040.00420.05
8.3.10.0000.00821.96
8.3.00.0000.00822.57
8.2.170.0060.00922.96
8.2.160.0140.00019.22
8.2.150.0040.00424.18
8.2.140.0030.00624.66
8.2.130.0100.00726.16
8.2.120.0030.00619.51
8.2.110.0040.00422.25
8.2.100.0110.00017.91
8.2.90.0000.00819.05
8.2.80.0000.00818.04
8.2.70.0040.00417.50
8.2.60.0050.00317.68
8.2.50.0050.00318.07
8.2.40.0080.00018.22
8.2.30.0040.00417.99
8.2.20.0070.00017.63
8.2.10.0040.00417.60
8.2.00.0000.00717.73
8.1.270.0000.00823.99
8.1.260.0080.00026.35
8.1.250.0040.00428.09
8.1.240.0040.00423.66
8.1.230.0100.00319.01
8.1.220.0040.00417.74
8.1.210.0030.00618.77
8.1.200.0030.00617.10
8.1.190.0040.00417.41
8.1.180.0050.00318.70
8.1.170.0030.00518.41
8.1.160.0040.00422.09
8.1.150.0030.00718.57
8.1.140.0040.00417.38
8.1.130.0030.00317.71
8.1.120.0030.00317.45
8.1.110.0040.00417.40
8.1.100.0000.00717.35
8.1.90.0060.00317.32
8.1.80.0030.00517.34
8.1.70.0040.00417.36
8.1.60.0030.00617.46
8.1.50.0020.00517.32
8.1.40.0030.00517.44
8.1.30.0050.00317.57
8.1.20.0000.00817.59
8.1.10.0050.00317.51
8.1.00.0030.00517.41
8.0.300.0040.00418.77
8.0.290.0040.00417.04
8.0.280.0040.00418.48
8.0.270.0000.00717.30
8.0.260.0070.00016.82
8.0.250.0000.00716.88
8.0.240.0040.00416.71
8.0.230.0040.00416.77
8.0.220.0030.00316.80
8.0.210.0050.00216.82
8.0.200.0070.00016.89
8.0.190.0030.00616.89
8.0.180.0000.00716.85
8.0.170.0000.00816.89
8.0.160.0070.00016.86
8.0.150.0000.00716.66
8.0.140.0070.00016.82
8.0.130.0000.00513.25
8.0.120.0000.00816.79
8.0.110.0000.00716.75
8.0.100.0000.00716.68
8.0.90.0040.00416.77
8.0.80.0110.00516.79
8.0.70.0050.00216.69
8.0.60.0040.00416.70
8.0.50.0000.00716.80
8.0.30.0100.01017.03
8.0.20.0090.01117.40
8.0.10.0040.00416.96
8.0.00.0090.00916.63
7.4.330.0000.00416.69
7.4.320.0070.00016.57
7.4.300.0030.00316.48
7.4.290.0060.00316.51
7.4.280.0030.00316.50
7.4.270.0040.00416.37
7.4.260.0060.00316.52
7.4.250.0000.00816.54
7.4.240.0030.00316.42
7.4.230.0030.00316.24
7.4.220.0100.00716.63
7.4.210.0080.00816.58
7.4.200.0070.00016.27
7.4.190.0070.00016.52
7.4.160.0110.00616.37
7.4.150.0030.01517.40
7.4.140.0100.01017.86
7.4.130.0050.01416.39
7.4.120.0090.00716.34
7.4.110.0100.01316.40
7.4.100.0130.00616.65
7.4.90.0140.00716.38
7.4.80.0100.00719.39
7.4.70.0030.02016.36
7.4.60.0120.00916.37
7.4.50.0050.00316.42
7.4.40.0070.00722.77
7.4.30.0040.01216.41
7.4.00.0070.00715.02
7.3.330.0050.00013.12
7.3.320.0050.00012.98
7.3.310.0000.00716.09
7.3.300.0070.00015.99
7.3.290.0080.00616.16
7.3.280.0060.00916.09
7.3.270.0120.00917.40
7.3.260.0030.01516.27
7.3.250.0040.01216.22
7.3.240.0060.01016.52
7.3.230.0070.01616.46
7.3.210.0090.00916.26
7.3.200.0110.00619.39
7.3.190.0140.00416.27
7.3.180.0160.00816.34
7.3.170.0160.00016.27
7.3.160.0060.00916.29
7.3.120.0030.01014.94
7.2.330.0090.00916.68
7.2.320.0050.01616.52
7.2.310.0120.00316.49
7.2.300.0030.01416.46
7.2.290.0040.01216.59
7.1.70.0000.00817.16
7.1.60.0130.00319.82
7.1.50.0000.01516.89
7.1.00.0000.07022.41
7.0.200.0000.00716.55
7.0.140.0000.07321.95
7.0.60.0130.07319.91
7.0.50.0130.07317.90
7.0.40.0070.05720.30
7.0.30.0330.08020.20
7.0.20.0370.06320.18
7.0.10.0300.09020.13
7.0.00.0100.07720.30
5.6.280.0000.07720.91
5.6.210.0030.08720.74
5.6.200.0000.06718.21
5.6.190.0070.04020.58
5.6.180.3130.05020.67
5.6.170.0200.04320.54
5.6.160.0100.05720.36
5.6.150.0070.08318.21
5.6.140.0000.05318.11
5.6.130.0100.05318.07
5.6.120.0130.07321.00
5.6.110.0070.07321.14
5.6.100.0170.08321.10
5.6.90.0070.06721.09
5.6.80.0070.07320.39
5.6.70.0300.05720.27
5.5.350.0430.06720.41
5.5.340.0100.05018.00
5.5.330.0000.09020.15
5.5.320.0370.05720.18
5.5.310.0270.05720.28
5.5.300.0030.04317.98
5.5.290.0130.06018.01
5.5.280.0100.06020.90
5.5.270.0170.07320.64
5.5.260.0030.04720.87
5.5.250.0000.05020.54
5.5.240.0100.08020.11
5.4.450.0230.03719.13
5.4.440.0230.04719.38
5.4.430.0130.04319.10
5.4.420.0200.04319.21
5.4.410.0230.03719.43
5.4.400.0170.04019.07
5.4.390.0270.04019.13
5.4.380.0100.04719.21
5.4.370.0230.03719.21
5.4.360.0200.04018.88
5.4.350.0200.04718.89
5.4.340.0230.03318.92
5.4.320.0200.04719.24
5.4.310.0130.04019.08
5.4.300.0230.04019.13
5.4.290.0130.04018.95
5.4.280.0200.03719.09
5.4.270.0200.03718.91
5.4.260.0200.03319.15
5.4.250.0270.03019.07
5.4.240.0130.04019.08
5.4.230.0200.04019.23
5.4.220.0270.03319.09
5.4.210.0200.03318.77
5.4.200.0270.03319.04
5.4.190.0170.04719.12
5.4.180.0170.04319.24
5.4.170.0270.04019.26
5.4.160.0270.06019.11
5.4.150.0170.05319.09
5.4.140.0270.03316.44
5.4.130.0230.03716.18
5.4.120.0230.04316.54
5.4.110.0200.07016.39
5.4.100.0370.06716.42
5.4.90.0200.05016.43
5.4.80.0370.02716.21
5.4.70.0200.04316.40
5.4.60.0270.03716.45
5.4.50.0200.04316.36
5.4.40.0330.06016.23
5.4.30.0270.03316.41
5.4.20.0200.07316.31
5.4.10.0200.04316.31
5.4.00.0200.06716.16
5.3.290.0230.06316.16
5.3.280.0270.07316.16
5.3.270.0270.07016.16
5.3.260.0230.05016.16
5.3.250.0370.06016.16
5.3.240.0300.07316.16
5.3.230.0370.05016.16
5.3.220.0230.05716.16
5.3.210.0200.04716.16
5.3.200.0230.07316.16
5.3.190.0200.05016.16
5.3.180.0270.07016.16
5.3.170.0270.07016.16
5.3.160.0270.06716.16
5.3.150.0330.05016.16
5.3.140.0200.04316.16
5.3.130.0300.07316.16
5.3.120.0330.04316.16
5.3.110.0300.06016.16
5.3.100.0300.04316.16
5.3.90.0270.07016.16
5.3.80.0270.04016.16
5.3.70.0230.04316.16
5.3.60.0270.04716.16
5.3.50.0200.04016.16
5.3.40.0230.03316.16
5.3.30.0300.06316.16
5.3.20.0270.06716.16
5.3.10.0300.05716.16
5.3.00.0300.03016.16
5.2.170.0200.02716.16
5.2.160.0200.02716.16
5.2.150.0300.04716.16
5.2.140.0230.03316.16
5.2.130.0230.05316.16
5.2.120.0270.04016.16
5.2.110.0300.05016.16
5.2.100.0200.06716.16
5.2.90.0330.04716.16
5.2.80.0270.03316.16
5.2.70.0230.03716.16
5.2.60.0200.04016.16
5.2.50.0200.05716.16
5.2.40.0270.05016.16
5.2.30.0230.04716.16
5.2.20.0170.04316.16
5.2.10.0230.05316.16
5.2.00.0230.03316.16
5.1.60.0200.02716.16
5.1.50.0170.04016.16
5.1.40.0170.04716.16
5.1.30.0170.02316.16
5.1.20.0230.04716.16
5.1.10.0170.05316.16
5.1.00.0170.04316.16
5.0.50.0170.04016.16
5.0.40.0070.03316.16
5.0.30.0070.04716.16
5.0.20.0070.02716.16
5.0.10.0100.04316.16
5.0.00.0170.06016.16
4.4.90.0170.03016.16
4.4.80.0170.02316.16
4.4.70.0070.02716.16
4.4.60.0100.03316.16
4.4.50.0130.02716.16
4.4.40.0100.03316.16
4.4.30.0070.02316.16
4.4.20.0100.02016.16
4.4.10.0030.02016.16
4.4.00.0130.05016.16
4.3.110.0100.02016.16
4.3.100.0100.01716.16
4.3.90.0130.03016.16
4.3.80.0070.03016.16
4.3.70.0130.03016.16
4.3.60.0100.03016.16
4.3.50.0070.03716.16
4.3.40.0100.04316.16
4.3.30.0070.02716.16
4.3.20.0030.03716.16
4.3.10.0030.02316.16
4.3.00.0030.03316.16

preferences:
54.89 ms | 400 KiB | 5 Q