3v4l.org

run code in 300+ PHP versions simultaneously
<?php //$arr = array(1,2,3,4,5,6,7,8,9,0); $arr = array(1,2,3,4,5,6,7, 8); $i = 0; $links_count = 3; $s = ''; while ($item = current($arr)) { $s .= !($i % $links_count) ? "<li>\n" : ""; $s .= "<a href='#'>$item</a>\n"; $s .= !(($i+1) % $links_count) ? "</li>\n" : ""; $i++; next($arr); } $s .= ($i % $links_count) ? "</li>\n" : ''; echo $s;

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.0080.00618.18
8.3.50.0160.00922.16
8.3.40.0040.01818.70
8.3.30.0120.00319.09
8.3.20.0000.00820.38
8.3.10.0050.00223.57
8.3.00.0070.00020.38
8.2.180.0060.00918.16
8.2.170.0110.00422.96
8.2.160.0090.00922.26
8.2.150.0080.00024.18
8.2.140.0120.00324.66
8.2.130.0000.00726.16
8.2.120.0040.00417.63
8.2.110.0040.00422.20
8.2.100.0110.00017.97
8.2.90.0070.00319.38
8.2.80.0000.00818.16
8.2.70.0080.00317.75
8.2.60.0030.00617.93
8.2.50.0050.00518.07
8.2.40.0040.00418.16
8.2.30.0040.00418.02
8.2.20.0000.00717.73
8.2.10.0000.00717.82
8.2.00.0000.00817.78
8.1.280.0100.00325.92
8.1.270.0000.00823.91
8.1.260.0080.00026.35
8.1.250.0080.00028.09
8.1.240.0030.00623.96
8.1.230.0060.00619.00
8.1.220.0040.00417.74
8.1.210.0000.00918.77
8.1.200.0090.00017.13
8.1.190.0090.00017.53
8.1.180.0040.00418.10
8.1.170.0030.00518.64
8.1.160.0040.00422.03
8.1.150.0000.00718.66
8.1.140.0000.00817.52
8.1.130.0080.00017.79
8.1.120.0040.00417.53
8.1.110.0040.00417.54
8.1.100.0040.00417.31
8.1.90.0000.00717.50
8.1.80.0000.00717.40
8.1.70.0000.00717.40
8.1.60.0030.00517.64
8.1.50.0040.00417.58
8.1.40.0060.00317.44
8.1.30.0050.00317.68
8.1.20.0000.00717.73
8.1.10.0060.00317.54
8.1.00.0000.00717.48
8.0.300.0030.00418.77
8.0.290.0040.00417.18
8.0.280.0000.00718.42
8.0.270.0030.00317.28
8.0.260.0070.00016.89
8.0.250.0070.00016.87
8.0.240.0000.00816.88
8.0.230.0040.00416.87
8.0.220.0030.00316.85
8.0.210.0030.00316.89
8.0.200.0030.00616.81
8.0.190.0030.00516.98
8.0.180.0060.00316.92
8.0.170.0050.00316.96
8.0.160.0050.00217.01
8.0.150.0000.00716.86
8.0.140.0040.00416.86
8.0.130.0000.00513.30
8.0.120.0050.00316.77
8.0.110.0070.00016.80
8.0.100.0070.00016.73
8.0.90.0070.00016.83
8.0.80.0070.00716.95
8.0.70.0070.00016.79
8.0.60.0030.00616.86
8.0.50.0040.00416.85
8.0.30.0130.00916.90
8.0.20.0100.01017.43
8.0.10.0060.00316.96
8.0.00.0130.00616.88
7.4.330.0050.00015.00
7.4.320.0000.00616.60
7.4.300.0070.00016.38
7.4.290.0050.00216.55
7.4.280.0040.00416.59
7.4.270.0030.00316.63
7.4.260.0040.00416.48
7.4.250.0000.00716.42
7.4.240.0050.00216.59
7.4.230.0070.00016.42
7.4.220.0070.00716.68
7.4.210.0040.01016.52
7.4.200.0030.00316.36
7.4.190.0030.00316.71
7.4.160.0090.00616.48
7.4.150.0070.01117.40
7.4.140.0020.01617.86
7.4.130.0090.00916.49
7.4.120.0090.01016.43
7.4.110.0090.00916.45
7.4.100.0170.00416.68
7.4.90.0130.01016.50
7.4.80.0130.00616.54
7.4.70.0080.00816.65
7.4.60.0100.00616.48
7.4.50.0000.00416.52
7.4.40.0030.01322.77
7.4.30.0120.00916.48
7.4.00.0070.00715.14
7.3.330.0070.00013.10
7.3.320.0050.00013.21
7.3.310.0030.00316.43
7.3.300.0000.00716.22
7.3.290.0030.01016.28
7.3.280.0080.00716.35
7.3.270.0120.00617.40
7.3.260.0070.01416.22
7.3.250.0100.01216.65
7.3.240.0100.00616.24
7.3.230.0060.00916.57
7.3.210.0180.00416.30
7.3.200.0170.00019.39
7.3.190.0070.01016.53
7.3.180.0060.01516.54
7.3.170.0130.00316.57
7.3.160.0130.00316.66
7.3.120.0040.01414.76
7.2.330.0140.00416.56
7.2.320.0070.01016.45
7.2.310.0130.00716.60
7.2.300.0120.00616.69
7.2.290.0070.01016.50
7.2.60.0100.00716.72
7.2.00.0040.01119.38
7.1.200.0030.01015.90
7.1.100.0040.00717.90
7.1.70.0000.00817.31
7.1.60.0090.00919.32
7.1.50.0030.01917.02
7.1.00.0030.07722.57
7.0.200.0090.00316.89
7.0.140.0030.07022.18
7.0.60.0200.07720.07
7.0.50.0100.04017.89
7.0.40.0100.05719.90
7.0.30.0300.07720.17
7.0.20.0230.07320.20
7.0.10.0370.07720.21
7.0.00.0070.09019.99
5.6.280.0070.07020.89
5.6.210.0070.06720.52
5.6.200.0030.08318.13
5.6.190.0070.04320.61
5.6.180.0500.07320.61
5.6.170.0130.07020.61
5.6.160.0070.04720.61
5.6.150.0100.07718.18
5.6.140.0200.06718.15
5.6.130.0070.08718.16
5.6.120.0000.06021.00
5.6.110.0030.05320.89
5.6.100.0100.07721.13
5.6.90.0130.04320.87
5.6.80.0100.03720.38
5.6.70.3930.04020.52
5.5.350.0070.08020.39
5.5.340.0030.04317.98
5.5.330.0100.04720.13
5.5.320.0030.07320.34
5.5.310.0300.06720.29
5.5.300.0230.06717.98
5.5.290.0030.05717.92
5.5.280.0130.04720.88
5.5.270.0130.07020.83
5.5.260.0070.07720.95
5.5.250.0070.07320.68
5.5.240.0070.04320.14
5.4.450.0200.04319.57
5.4.440.0230.03319.54
5.4.430.0230.04719.54
5.4.420.0230.08019.48
5.4.410.0370.05019.28
5.4.400.0200.04318.81
5.4.390.0230.06019.09
5.4.380.0270.05019.06
5.4.370.0270.04018.79
5.4.360.0230.07719.09
5.4.350.0300.04019.25
5.4.340.0200.04318.80
5.4.320.0230.06319.24
5.4.310.0300.05019.16
5.4.300.0230.04019.09
5.4.290.0330.04319.13
5.4.280.0270.04318.91
5.4.270.0270.05318.93
5.4.260.0300.03018.78
5.4.250.0130.04319.23
5.4.240.0200.03718.80
5.4.230.0230.03319.07
5.4.220.0230.04319.13
5.4.210.0200.03718.88
5.4.200.0230.03719.08
5.4.190.0270.03318.91
5.4.180.0130.04318.77
5.4.170.0200.04018.78
5.4.160.0230.04018.79
5.4.150.0270.03019.22
5.4.140.0270.04016.25
5.4.130.0300.06016.44
5.4.120.0270.06716.42
5.4.110.0270.06716.48
5.4.100.0230.04716.34
5.4.90.0230.07316.41
5.4.80.0200.05016.46
5.4.70.0230.05716.39
5.4.60.0270.06716.32
5.4.50.0230.03316.27
5.4.40.0170.03716.41
5.4.30.0200.04316.46
5.4.20.0200.03716.27
5.4.10.0230.04716.41
5.4.00.0200.03715.99
5.3.290.0200.06014.75
5.3.280.0500.04014.43
5.3.270.0230.04314.65
5.3.260.0200.04314.63
5.3.250.0270.06714.43
5.3.240.0300.04014.60
5.3.230.0230.05714.44
5.3.220.0230.03314.40
5.3.210.0200.04314.51
5.3.200.0270.06714.42
5.3.190.0170.05714.54
5.3.180.0270.07314.65
5.3.170.0230.04014.42
5.3.160.0370.05014.44
5.3.150.0100.06014.61
5.3.140.0270.05314.38
5.3.130.0170.04014.38
5.3.120.0270.03714.50
5.3.110.0270.06714.50
5.3.100.0200.06314.08
5.3.90.0130.05013.95
5.3.80.0270.06713.96
5.3.70.0230.04314.00
5.3.60.0300.05014.05
5.3.50.0200.03713.72
5.3.40.0130.05713.97
5.3.30.0200.05313.86
5.3.20.0230.06313.55
5.3.10.0400.03013.64
5.3.00.0230.06013.47
5.2.170.0270.05312.23
5.2.160.0170.04312.23
5.2.150.0200.03312.23
5.2.140.0100.03712.23
5.2.130.0300.02012.23
5.2.120.0230.05012.23
5.2.110.0170.05012.23
5.2.100.0330.04712.23
5.2.90.0230.02712.23
5.2.80.0270.02712.23
5.2.70.0300.05012.23
5.2.60.0130.06012.23
5.2.50.0230.05712.23
5.2.40.0130.06312.23
5.2.30.0130.06012.23
5.2.20.0200.04012.23
5.2.10.0070.03312.23
5.2.00.0130.04712.23
5.1.60.0070.04012.23
5.1.50.0130.05012.23
5.1.40.0100.04312.23
5.1.30.0100.03712.23
5.1.20.0130.05312.23
5.1.10.0130.05012.23
5.1.00.0200.03012.23
5.0.50.0070.04312.23
5.0.40.0070.03712.23
5.0.30.0100.06012.23
5.0.20.0130.03312.23
5.0.10.0070.03012.23
5.0.00.0100.05312.23
4.4.90.0100.01712.23
4.4.80.0130.03012.23
4.4.70.0070.02312.23
4.4.60.0030.02012.23
4.4.50.0130.03312.23
4.4.40.0100.03712.23
4.4.30.0070.02312.23
4.4.20.0070.03312.23
4.4.10.0070.03712.23
4.4.00.0070.03312.23
4.3.110.0070.02012.23
4.3.100.0070.03712.23
4.3.90.0130.02012.23
4.3.80.0100.03312.23
4.3.70.0100.01712.23
4.3.60.0100.03012.23
4.3.50.0070.04012.23
4.3.40.0070.03712.23
4.3.30.0100.03312.23
4.3.20.0070.03312.23
4.3.10.0100.03012.23
4.3.00.0030.03712.23

preferences:
52.53 ms | 401 KiB | 5 Q