3v4l.org

run code in 300+ PHP versions simultaneously
<?php function floorDiff(string $input): int { if ($input === '(') { return 1; } if ($input === ')') { return 1; } } assert(floorDiff('(') === 1); assert(floorDiff(')') === -1);

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.0150.00616.63
8.3.50.0170.01522.04
8.3.40.0040.01119.00
8.3.30.0140.00718.57
8.3.20.0030.01020.22
8.3.10.0000.00823.66
8.3.00.0000.00819.91
8.2.180.0170.00316.63
8.2.170.0150.00622.96
8.2.160.0070.01320.38
8.2.150.0050.00324.18
8.2.140.0080.00024.66
8.2.130.0080.00019.38
8.2.120.0080.00026.35
8.2.110.0040.00422.30
8.2.100.0120.00017.93
8.2.90.0030.00619.23
8.2.80.0080.00017.97
8.2.70.0040.00417.50
8.2.60.0030.00617.80
8.2.50.0040.00418.07
8.2.40.0080.00022.28
8.2.30.0040.00420.57
8.2.20.0000.00717.61
8.2.10.0080.00017.88
8.2.00.0000.00718.00
8.1.280.0090.00925.92
8.1.270.0050.00520.24
8.1.260.0040.00428.09
8.1.250.0040.00428.09
8.1.240.0040.00423.99
8.1.230.0070.00419.22
8.1.220.0000.00817.74
8.1.210.0040.00718.77
8.1.200.0090.00017.23
8.1.190.0060.00317.22
8.1.180.0050.00318.10
8.1.170.0030.00518.66
8.1.160.0000.00820.70
8.1.150.0030.00518.83
8.1.140.0080.00019.51
8.1.130.0000.00717.57
8.1.120.0000.00717.23
8.1.110.0040.00417.18
8.1.100.0030.00617.26
8.1.90.0040.00417.19
8.1.80.0030.00517.28
8.1.70.0070.00017.14
8.1.60.0040.00417.42
8.1.50.0040.00417.52
8.1.40.0020.00517.52
8.1.30.0030.00517.68
8.1.20.0050.00317.48
8.1.10.0040.00417.48
8.1.00.0040.00417.49
8.0.300.0040.00418.77
8.0.290.0040.00416.63
8.0.280.0030.00318.38
8.0.270.0070.00017.21
8.0.260.0030.00317.08
8.0.250.0030.00316.95
8.0.240.0000.00716.86
8.0.230.0030.00317.00
8.0.220.0030.00316.89
8.0.210.0000.00716.96
8.0.200.0000.00716.87
8.0.190.0040.00716.91
8.0.180.0080.00016.93
8.0.170.0080.00016.92
8.0.160.0070.00016.96
8.0.150.0030.00516.88
8.0.140.0020.00516.73
8.0.130.0030.00313.41
8.0.120.0040.00416.91
8.0.110.0070.00016.83
8.0.100.0040.00416.69
8.0.90.0030.00616.75
8.0.80.0090.00616.88
8.0.70.0000.00716.96
8.0.60.0000.00716.91
8.0.50.0040.00416.95
8.0.30.0060.01317.03
8.0.20.0080.01017.40
8.0.10.0000.00717.02
8.0.00.0130.00416.53
7.4.330.0000.00516.82
7.4.320.0030.00316.48
7.4.300.0060.00016.35
7.4.290.0000.00716.53
7.4.280.0040.00416.54
7.4.270.0070.00016.38
7.4.260.0080.00016.57
7.4.250.0040.00416.43
7.4.240.0060.00116.54
7.4.230.0000.00716.34
7.4.220.0110.00716.53
7.4.210.0060.00916.66
7.4.200.0070.00016.55
7.4.160.0110.00616.26
7.4.150.0090.00917.40
7.4.140.0090.01217.86
7.4.130.0080.01016.75
7.4.120.0120.00516.59
7.4.110.0170.00316.63
7.4.100.0070.01316.43
7.4.90.0150.00616.55
7.4.80.0060.01919.39
7.4.70.0030.01316.58
7.4.60.0120.00316.61
7.4.50.0000.01216.29
7.4.40.0000.02316.57
7.4.30.0090.01316.45
7.4.00.0070.01115.25
7.3.330.0020.00213.25
7.3.320.0050.00013.30
7.3.310.0070.00016.41
7.3.300.0000.00716.41
7.3.290.0090.00616.43
7.3.280.0080.01016.43
7.3.270.0080.00817.40
7.3.260.0110.00516.36
7.3.250.0110.00916.50
7.3.240.0100.00616.48
7.3.230.0140.00416.57
7.3.210.0100.00716.47
7.3.200.0130.00316.40
7.3.190.0140.00916.45
7.3.180.0060.00916.64
7.3.170.0090.00616.39
7.3.160.0100.01016.54
7.2.330.0140.00416.39
7.2.320.0120.00916.20
7.2.310.0070.01716.16
7.2.300.0030.01316.68
7.2.290.0030.01316.27
7.2.80.0060.00616.32
7.2.60.0030.00916.38
7.2.00.0060.00619.46
7.1.200.0070.01015.89
7.1.100.0030.00717.88
7.1.70.0030.00517.02
7.1.60.0030.02119.52
7.1.50.0100.00617.03
7.1.00.0030.07322.40
7.0.200.0000.01016.64
7.0.60.0130.06719.96
7.0.50.0000.04717.73
7.0.40.0070.04020.24
7.0.30.0230.05720.23
7.0.20.0370.07320.30
7.0.10.0030.05320.19
7.0.00.0130.06720.25
5.6.280.0070.04021.10
5.6.210.0130.07320.54
5.6.200.0200.06718.29
5.6.190.0070.07720.65
5.6.180.0400.04020.61
5.6.170.0270.06020.46
5.6.160.0070.09020.55
5.6.150.0000.05018.29
5.6.140.0070.06318.28
5.6.130.0200.03718.18
5.6.120.0100.08321.05
5.6.110.0100.06720.98
5.6.100.0070.03721.13
5.6.90.0130.07020.97
5.6.80.0070.06320.50
5.5.350.0200.04020.33
5.5.340.0100.07718.01
5.5.330.0030.05320.38
5.5.320.0130.04320.34
5.5.310.0270.03720.34
5.5.300.0100.06717.91
5.5.290.0070.08018.08
5.5.280.0070.06720.89
5.5.270.0200.06720.74
5.5.260.0000.07320.89
5.5.250.0030.08320.77
5.5.240.0200.09720.26

preferences:
56.31 ms | 401 KiB | 5 Q