3v4l.org

run code in 300+ PHP versions simultaneously
<?php $one = [6,5,4,3,2,1,0,7]; $two = [0,1,2,3,4,5,6,7]; // 3 is the answer for($i = 0; $i < count($one); $i++){ if($one[$i] === $two[$i]){ echo "the answer is " . $one[$i] . "\n"; break 1; // remove this line if you want also 7 to show up } }

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.4.120.0090.01120.74
8.4.110.0140.00622.20
8.4.100.0150.00617.69
8.4.90.0120.00820.44
8.4.80.0090.01119.14
8.4.70.0130.00818.86
8.4.60.0070.01420.57
8.4.50.0130.00618.63
8.4.40.0120.00917.93
8.4.30.0130.00620.51
8.4.20.0170.00319.50
8.4.10.0060.00317.63
8.3.250.0140.00517.17
8.3.240.0070.00616.48
8.3.230.0070.00916.74
8.3.220.0090.00919.05
8.3.210.0110.00716.62
8.3.200.0110.00616.51
8.3.190.0120.00817.07
8.3.180.0100.01018.85
8.3.170.0070.01117.34
8.3.160.0060.01316.70
8.3.150.0120.00616.47
8.3.140.0040.00416.54
8.3.130.0070.00718.47
8.3.120.0060.00320.60
8.3.110.0060.00320.94
8.3.100.0080.00824.06
8.3.90.0090.00926.77
8.3.80.0040.00416.63
8.3.70.0120.00618.31
8.3.60.0040.01418.28
8.3.50.0070.01019.61
8.3.40.0140.00719.08
8.3.30.0070.00718.85
8.3.20.0070.00024.18
8.3.10.0090.00024.66
8.3.00.0070.00026.16
8.2.290.0130.00616.66
8.2.280.0130.00718.46
8.2.270.0110.00718.64
8.2.260.0090.00916.86
8.2.250.0060.00316.36
8.2.240.0040.00818.16
8.2.230.0090.00022.58
8.2.220.0060.00337.54
8.2.210.0000.00826.77
8.2.200.0030.00616.50
8.2.190.0140.00716.63
8.2.180.0110.00425.92
8.2.170.0110.00418.85
8.2.160.0100.00322.96
8.2.150.0040.00425.66
8.2.140.0040.00424.66
8.2.130.0040.00426.16
8.2.120.0040.00426.16
8.2.110.0040.00420.53
8.2.100.0110.00017.91
8.2.90.0050.00318.22
8.2.80.0040.00418.28
8.2.70.0080.00017.63
8.2.60.0040.00417.61
8.2.50.0050.00317.55
8.2.40.0040.00417.75
8.2.30.0040.00417.80
8.2.20.0000.00719.38
8.2.10.0000.00817.70
8.2.00.0040.00419.11
8.1.330.0120.00816.10
8.1.320.0110.00918.12
8.1.310.0050.00318.44
8.1.300.0030.00617.75
8.1.290.0080.00430.84
8.1.280.0070.01425.92
8.1.270.0040.00423.99
8.1.260.0000.00826.35
8.1.250.0040.00428.09
8.1.240.0030.00623.74
8.1.230.0070.00322.04
8.1.220.0000.00817.79
8.1.210.0040.00419.04
8.1.200.0080.00017.22
8.1.190.0070.00017.23
8.1.180.0040.00418.10
8.1.170.0080.00017.62
8.1.160.0000.00918.94
8.1.150.0000.00718.59
8.1.140.0040.00417.52
8.1.130.0030.00318.90
8.1.120.0040.00417.42
8.1.110.0070.00017.38
8.1.100.0030.00317.50
8.1.90.0030.00517.38
8.1.80.0070.00317.39
8.1.70.0000.00717.46
8.1.60.0030.00517.47
8.1.50.0000.00817.50
8.1.40.0020.00517.41
8.1.30.0000.00817.58
8.1.20.0030.00617.73
8.1.10.0040.00417.44
8.1.00.0040.00417.37
8.0.300.0070.00019.98
8.0.290.0060.00316.63
8.0.280.0000.00717.93
8.0.270.0050.00316.79
8.0.260.0050.00318.55
8.0.250.0030.00316.95
8.0.240.0000.00616.98
8.0.230.0040.00416.99
8.0.220.0030.00416.80
8.0.210.0030.00516.88
8.0.200.0000.00716.88
8.0.190.0040.00416.79
8.0.180.0040.00416.93
8.0.170.0080.00016.95
8.0.160.0000.00816.86
8.0.150.0080.00016.73
8.0.140.0000.01016.78
8.0.130.0000.00713.36
8.0.120.0020.00513.36
8.0.110.0120.00013.38
8.0.100.0080.00513.21
8.0.90.0050.00513.30
8.0.80.0090.00313.34
8.0.70.0120.00013.23
8.0.60.0100.00313.30
8.0.50.0060.00613.33
8.0.30.0080.00413.35
8.0.20.0080.00513.38
8.0.10.0080.00513.43
8.0.00.0070.00013.49
7.4.330.0000.00515.55
7.4.320.0030.00316.43
7.4.300.0060.00016.50
7.4.290.0040.00416.56
7.4.280.0000.00716.59
7.4.270.0000.00716.61
7.4.260.0050.00013.26
7.4.250.0090.00613.25
7.4.240.0110.00313.29
7.4.230.0090.00313.36
7.4.220.0030.00713.19
7.4.210.0100.00313.23
7.4.200.0090.00513.39
7.4.190.0100.00313.41
7.4.180.0110.00313.40
7.4.160.0120.00313.28
7.4.150.0110.00313.39
7.4.140.0090.00313.20
7.4.130.0130.00013.09
7.4.120.0060.00613.33
7.4.110.0140.00013.14
7.4.100.0140.00013.30
7.4.90.0100.00313.21
7.4.80.0120.00013.16
7.4.70.0100.00313.20
7.4.60.0090.00313.19
7.4.50.0100.00313.21
7.4.40.0100.00513.13
7.4.30.0080.00513.25
7.4.20.0130.00013.25
7.4.10.0110.00013.20
7.4.00.0040.00713.05
7.3.330.0000.00616.12
7.3.320.0100.00013.07
7.3.310.0090.00412.95
7.3.300.0060.00713.15
7.3.290.0070.00713.06
7.3.280.0070.00413.00
7.3.270.0030.00613.00
7.3.260.0020.00813.15
7.3.250.0060.00313.00
7.3.240.0100.00013.15
7.3.230.0080.00012.80
7.3.220.0040.00413.08
7.3.210.0090.00013.11
7.3.200.0070.00012.99
7.3.190.0050.00312.97
7.3.180.0000.00813.09
7.3.170.0040.00413.03
7.3.160.0030.00613.16
7.3.150.0090.00013.11
7.3.140.0040.00413.09
7.3.130.0070.00313.18
7.3.120.0080.00413.01
7.3.110.0080.00613.08
7.3.100.0080.00313.04
7.3.90.0130.00013.37
7.3.80.0120.00313.10
7.3.70.0130.00013.12
7.3.60.0090.00613.31
7.3.50.0120.00213.27
7.3.40.0140.00013.35
7.3.30.0130.00013.24
7.3.20.0070.00713.18
7.3.10.0120.00313.26
7.3.00.0130.00915.02

preferences:
28.19 ms | 403 KiB | 5 Q