3v4l.org

run code in 300+ PHP versions simultaneously
<?php $var = '42'; echo "the answer is $var\n";//you don't need the {}, it's just a scalar type $ar = ['answer' => 42]; //it's an array, no you do need the {} echo "the answer is {$ar['answer']}\n";

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.0120.00318.30
8.3.50.0070.00716.19
8.3.40.0060.00918.66
8.3.30.0140.00018.61
8.3.20.0000.00721.86
8.3.10.0040.00423.46
8.3.00.0040.00418.03
8.2.180.0070.00718.28
8.2.170.0160.00322.96
8.2.160.0070.01021.20
8.2.150.0040.00424.18
8.2.140.0070.00024.66
8.2.130.0080.00026.16
8.2.120.0040.00419.97
8.2.110.0100.00020.94
8.2.100.0080.00417.84
8.2.90.0040.00420.42
8.2.80.0080.00020.50
8.2.70.0050.00317.63
8.2.60.0040.00417.63
8.2.50.0080.00018.05
8.2.40.0040.00419.48
8.2.30.0030.00720.31
8.2.20.0080.00018.03
8.2.10.0040.00418.04
8.2.00.0000.00718.02
8.1.280.0110.00825.92
8.1.270.0040.00423.84
8.1.260.0080.00026.35
8.1.250.0030.00628.09
8.1.240.0060.00322.05
8.1.230.0000.01320.84
8.1.220.0000.00917.74
8.1.210.0040.00418.91
8.1.200.0030.00517.39
8.1.190.0000.00917.23
8.1.180.0050.00318.10
8.1.170.0030.00617.62
8.1.160.0000.00718.86
8.1.150.0020.00520.21
8.1.140.0040.00419.42
8.1.130.0030.00318.77
8.1.120.0040.00417.23
8.1.110.0040.00417.43
8.1.100.0000.00717.41
8.1.90.0050.00317.29
8.1.80.0040.00417.40
8.1.70.0030.00317.39
8.1.60.0060.00617.49
8.1.50.0000.00717.46
8.1.40.0040.00417.41
8.1.30.0000.00817.62
8.1.20.0070.00017.50
8.1.10.0020.00517.60
8.1.00.0040.00417.54
8.0.300.0040.00420.16
8.0.290.0000.00716.63
8.0.280.0000.00818.43
8.0.270.0030.00317.16
8.0.260.0030.00516.73
8.0.250.0030.00316.82
8.0.240.0000.00716.85
8.0.230.0070.00016.85
8.0.220.0040.00416.91
8.0.210.0050.00316.86
8.0.200.0000.00716.80
8.0.190.0030.00516.94
8.0.180.0040.00416.94
8.0.170.0070.00316.93
8.0.160.0000.00816.92
8.0.150.0070.00016.88
8.0.140.0000.00716.78
8.0.130.0070.00013.35
8.0.120.0000.00716.83
8.0.110.0000.00716.90
8.0.100.0000.00716.85
8.0.90.0040.00416.86
8.0.80.0030.01216.91
8.0.70.0030.00516.84
8.0.60.0080.00016.78
8.0.50.0040.00416.89
8.0.30.0090.01217.08
8.0.20.0100.00917.40
8.0.10.0070.00016.93
8.0.00.0030.01316.97
7.4.330.0050.00015.55
7.4.320.0070.00016.34
7.4.300.0000.00716.43
7.4.290.0040.00416.42
7.4.280.0060.00316.49
7.4.270.0030.00316.40
7.4.260.0040.00416.27
7.4.250.0070.00016.38
7.4.240.0020.00516.38
7.4.230.0000.00716.45
7.4.220.0060.01916.44
7.4.210.0090.00616.51
7.4.200.0000.00716.47
7.4.160.0100.00616.47
7.4.150.0070.01117.40
7.4.140.0080.01017.86
7.4.130.0070.01016.56
7.4.120.0100.00716.38
7.4.110.0070.01016.63
7.4.100.0150.00916.39
7.4.90.0150.00616.52
7.4.80.0040.01819.39
7.4.70.0140.00316.45
7.4.60.0040.01216.53
7.4.50.0070.00716.38
7.4.40.0100.00616.52
7.4.30.0100.00716.38
7.4.00.0100.00614.98
7.3.330.0030.00312.99
7.3.320.0030.00312.92
7.3.310.0070.00016.16
7.3.300.0070.00016.04
7.3.290.0100.00716.26
7.3.280.0090.00616.25
7.3.270.0140.00317.40
7.3.260.0120.00716.47
7.3.250.0100.01116.35
7.3.240.0100.01116.55
7.3.230.0040.01416.35
7.3.210.0100.01216.25
7.3.200.0100.00716.61
7.3.190.0100.00716.28
7.3.180.0120.00616.47
7.3.170.0070.01016.52
7.3.160.0060.00916.53
7.3.10.0060.00916.54
7.3.00.0050.00616.52
7.2.330.0070.01016.60
7.2.320.0130.00616.28
7.2.310.0070.01016.53
7.2.300.0110.01316.46
7.2.290.0130.00416.66
7.2.130.0090.00516.85
7.2.120.0050.00616.73
7.2.110.0070.00816.68
7.2.100.0050.00916.66
7.2.90.0040.00816.59
7.2.80.0030.00916.85
7.2.70.0020.01316.48
7.2.60.0050.01116.76
7.2.50.0080.00816.84
7.2.40.0070.00616.63
7.2.30.0080.00916.75
7.2.20.0090.00616.81
7.2.10.0070.00516.80
7.2.00.0030.00916.82
7.1.250.0020.01015.60
7.1.240.0070.00415.42
7.1.230.0030.00715.37
7.1.220.0060.00315.67
7.1.210.0040.00415.59
7.1.200.0050.00715.57
7.1.190.0030.00915.52
7.1.180.0090.00615.67
7.1.170.0070.00715.59
7.1.160.0050.00515.57
7.1.150.0070.00715.54
7.1.140.0000.00915.82
7.1.130.0060.00615.81
7.1.120.0100.00315.68
7.1.110.0040.00815.61
7.1.100.0030.01315.48
7.1.90.0060.00315.30
7.1.80.0100.00315.73
7.1.70.0040.00816.16
7.1.60.0280.01024.44
7.1.50.0280.01024.19
7.1.40.0320.01023.86
7.1.30.0330.00724.15
7.1.20.0350.00724.13
7.1.10.0220.01115.10
7.1.00.0200.01015.37
7.0.330.0030.00715.12
7.0.320.0000.01115.50
7.0.310.0100.00315.02
7.0.300.0000.01015.39
7.0.290.0080.00515.24
7.0.280.0000.01315.38
7.0.270.0040.00815.17
7.0.260.0040.00415.16
7.0.250.0060.00315.46
7.0.240.0030.01015.23
7.0.230.0060.00315.41
7.0.220.0040.01014.98
7.0.210.0030.00615.34
7.0.200.0280.00715.02
7.0.190.0220.01115.08
7.0.180.0180.01114.86
7.0.170.0210.00814.85
7.0.160.0290.00414.86
7.0.150.0270.00714.82
7.0.140.0200.01214.79
7.0.130.0220.01115.08
7.0.120.0620.00815.03
7.0.110.0320.00714.96
7.0.100.0330.00614.79
7.0.90.0280.01214.88
7.0.80.0250.00814.79
7.0.70.0270.00514.94
7.0.60.0250.00514.73
7.0.50.0230.00814.83
7.0.40.0400.00514.03
7.0.30.0450.01013.98
7.0.20.0280.01014.00
7.0.10.0220.00913.94
7.0.00.0270.00813.97
5.6.380.0030.00614.41

preferences:
37.29 ms | 400 KiB | 5 Q