3v4l.org

run code in 300+ PHP versions simultaneously
<?php /* http://3v4l.org/DCTnA */ /* < [1] 2 3 ... 22 23 > < 1 [2] 3 ... 22 23 > < 1 2 [3] 4 ... 22 23 > < 1 2 3 [4] 5 ... 22 23 > < 1 2 ... 4 [5] 6 ... 22 23 > < 1 2 ... 5 [6] 7 ... 22 23 > ... < 1 2 ... 18 [19] 20 ... 22 23 > */ $currentpageid = $nmstart = 3; $nrtotal = 23; $nrposts = 1; $pages = ''; $ssPagingStartCount = 3; $ssPagingCurrentCount = 3; $ssPagingEndCount = 2; $totalpages = ceil($nrtotal / $nrposts); if ($totalpages > 1 ){ /* for ($x = 0; $x < $totalpages; ++$x) { $inc = $x * $nrposts; $display = $x + 1; if($inc != $nmstart) { $pages .= "\n<a class=\"nl_page\" href='" . "nmstart=$inc'>".$display."</a>"; } else { $pages .= "\n<span class=\"nl_page nl_page__currentpage\">".$display."</span>"; } } */ if ( ($currentpageid >= 0) && ($currentpageid < $ssPagingStartCount) ) { for ($x = 0; (($x <= max($ssPagingStartCount, ($currentpageid + (int)($ssPagingCurrentCount/2)))) && ($x < $totalpages)); ++$x) { $inc = $x * $nrposts; $display = $x + 1; if ($inc != $nmstart) { $pages .= "\n<a class=\"nl_page\" href='" . "nmstart=$inc'>".$display."</a>"; } else { $pages .= "\n<span class=\"nl_page nl_page__currentpage\">".$display."</span>"; } } } } var_dump($pages); ?>

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.0090.00616.50
8.3.50.0110.01022.00
8.3.40.0110.00418.84
8.3.30.0120.00919.22
8.3.20.0000.00920.16
8.3.10.0040.00421.60
8.3.00.0000.00919.15
8.2.180.0040.01116.38
8.2.170.0160.00622.96
8.2.160.0070.00722.20
8.2.150.0050.00324.18
8.2.140.0140.00424.66
8.2.130.0050.00326.16
8.2.120.0050.00319.64
8.2.110.0040.00419.36
8.2.100.0080.00417.75
8.2.90.0000.00819.07
8.2.80.0040.00417.97
8.2.70.0040.00417.50
8.2.60.0070.00018.03
8.2.50.0040.00418.07
8.2.40.0030.00619.88
8.2.30.0020.00518.06
8.2.20.0000.00717.59
8.2.10.0000.00818.15
8.2.00.0040.00417.74
8.1.280.0100.01025.92
8.1.270.0120.00320.65
8.1.260.0080.00026.35
8.1.250.0070.00028.09
8.1.240.0090.00023.87
8.1.230.0120.00018.78
8.1.220.0080.00017.78
8.1.210.0040.00418.77
8.1.200.0030.00617.35
8.1.190.0050.00317.35
8.1.180.0000.00718.10
8.1.170.0050.00320.48
8.1.160.0040.00422.02
8.1.150.0040.00418.76
8.1.140.0000.00717.36
8.1.130.0030.00317.73
8.1.120.0000.00717.48
8.1.110.0040.00417.46
8.1.100.0040.00317.49
8.1.90.0000.00717.51
8.1.80.0070.00017.47
8.1.70.0000.00717.48
8.1.60.0080.00017.57
8.1.50.0000.00817.51
8.1.40.0030.00517.48
8.1.30.0000.00917.60
8.1.20.0020.00517.66
8.1.10.0040.00417.46
8.1.00.0050.00217.42
8.0.300.0040.00418.77
8.0.290.0050.00916.63
8.0.280.0040.00418.51
8.0.270.0000.00717.16
8.0.260.0070.00017.30
8.0.250.0000.00716.90
8.0.240.0030.00316.94
8.0.230.0000.00716.85
8.0.220.0000.00816.93
8.0.210.0080.00016.78
8.0.200.0070.00016.96
8.0.190.0040.00416.97
8.0.180.0000.00716.80
8.0.170.0040.00417.00
8.0.160.0070.00016.82
8.0.150.0070.00016.87
8.0.140.0000.00816.82
8.0.130.0030.00313.27
8.0.120.0050.00316.84
8.0.110.0000.00716.75
8.0.100.0070.00016.95
8.0.90.0030.00516.93
8.0.80.0040.01216.84
8.0.70.0000.00716.71
8.0.60.0000.00716.86
8.0.50.0000.00716.78
8.0.30.0100.01116.89
8.0.20.0100.00817.40
8.0.10.0040.00416.86
8.0.00.0090.00916.68
7.4.330.0050.00015.03
7.4.320.0030.00316.60
7.4.300.0080.00016.55
7.4.290.0040.00416.48
7.4.280.0000.00716.49
7.4.270.0060.00016.65
7.4.260.0000.00716.54
7.4.250.0030.00516.45
7.4.240.0030.00316.54
7.4.230.0030.00316.25
7.4.220.0120.00616.60
7.4.210.0130.00016.42
7.4.200.0030.00316.50
7.4.160.0030.01316.45
7.4.150.0150.00917.40
7.4.140.0110.01117.86
7.4.130.0090.00816.47
7.4.120.0110.00816.58
7.4.110.0160.00016.42
7.4.100.0120.00816.36
7.4.90.0030.01416.39
7.4.80.0090.00919.39
7.4.70.0070.01016.33
7.4.60.0090.00616.48
7.4.50.0050.00016.51
7.4.40.0070.01016.56
7.4.30.0150.00316.61
7.4.00.0110.00014.63
7.3.330.0000.00613.25
7.3.320.0100.00513.15
7.3.310.0070.00016.23
7.3.300.0040.00416.30
7.3.290.0070.00716.29
7.3.280.0100.00516.24
7.3.270.0170.00717.40
7.3.260.0120.01016.36
7.3.250.0070.01416.39
7.3.240.0110.00616.53
7.3.230.0130.00516.41
7.3.210.0130.00416.52
7.3.200.0100.00619.39
7.3.190.0100.01016.60
7.3.180.0110.01116.46
7.3.170.0180.00616.40
7.3.160.0110.00316.28
7.3.10.0030.01016.65
7.3.00.0070.00316.50
7.2.330.0090.00916.75
7.2.320.0100.00716.62
7.2.310.0100.01016.74
7.2.300.0140.00416.41
7.2.290.0130.00916.63
7.2.130.0000.01117.04
7.2.120.0040.00716.64
7.2.110.0040.00416.98
7.2.100.0080.00316.77
7.2.90.0040.00817.05
7.2.80.0030.00617.09
7.2.70.0030.00616.80
7.2.60.0070.00717.01
7.2.50.0000.01116.97
7.2.40.0000.01216.94
7.2.30.0040.01116.95
7.2.20.0030.01016.88
7.2.10.0000.00916.64
7.2.00.0090.00417.95
7.1.250.0000.01015.94
7.1.200.0000.01115.71
7.1.100.0030.01018.29
7.1.70.0030.00617.18
7.1.60.0000.02419.46
7.1.50.0200.01334.79
7.1.00.0100.07022.36
7.0.200.0030.00316.43
7.0.140.0000.04022.09
7.0.70.5030.03019.95
7.0.60.0030.09020.01
7.0.50.0070.06717.94
7.0.40.0030.09320.04
7.0.30.0170.05020.33
7.0.20.0230.06020.16
7.0.10.0330.08020.18
7.0.00.0130.05720.18
5.6.280.0070.07320.82
5.6.210.0170.07720.50
5.6.200.0130.08318.19
5.6.190.0170.07320.66
5.6.180.0170.04020.43
5.6.170.0230.04320.62
5.6.160.0130.03720.47
5.6.150.0000.08318.19
5.6.140.0070.04718.18
5.6.130.0000.07718.18
5.6.120.0100.07320.98
5.6.110.0100.08021.09
5.6.100.0030.08020.88
5.6.90.0030.06321.09
5.6.80.0030.08320.34
5.6.70.0270.07320.32
5.5.350.0170.06020.46
5.5.340.0070.08017.97
5.5.330.0130.08320.19
5.5.320.0070.08020.57
5.5.310.0230.08020.32
5.5.300.0070.04017.94
5.5.290.0130.07317.95
5.5.280.0030.04720.80
5.5.270.0100.08020.84
5.5.260.0200.06020.89
5.5.250.0130.07320.66
5.5.240.0130.07020.17
5.4.450.0570.07719.55
5.4.440.0100.06319.47
5.4.430.0270.04319.58
5.4.420.0270.04019.32
5.4.410.0070.06319.36
5.4.400.1000.04318.77
5.4.390.0800.05718.59
5.4.380.0830.05318.61
5.4.370.0830.05318.74
5.4.360.0800.05718.59
5.4.350.0830.06318.75
5.4.340.0530.05718.61
5.4.320.0900.05318.49
5.4.310.0800.05318.50
5.4.300.0770.05718.56
5.4.290.0730.05318.64
5.4.280.0800.05318.73
5.4.270.0800.05718.71
5.4.260.0830.05318.71
5.4.250.0800.05318.63
5.4.240.0800.06018.49
5.4.230.0770.05018.66
5.4.220.0800.04318.55
5.4.210.1200.05318.57
5.4.200.1270.04016.63
5.4.190.1070.04718.66
5.4.180.1070.05718.70
5.4.170.1200.05318.69
5.4.160.0900.05018.66
5.4.150.1000.04718.66
5.4.140.0770.06016.38
5.4.130.0800.05716.23
5.4.120.0730.05316.22
5.4.110.0730.05016.07
5.4.100.0970.07316.32
5.4.90.0900.04316.27
5.4.80.0700.05316.16
5.4.70.0870.05316.29
5.4.60.1000.05016.23
5.4.50.0570.05016.29
5.4.40.0770.05316.19
5.4.30.0770.06316.13
5.4.20.1200.05016.27
5.4.10.1100.04716.27
5.4.00.1000.06015.52
5.3.290.0970.06014.73
5.3.280.1000.05714.52
5.3.270.1270.05314.59
5.3.260.2270.05314.61
5.3.250.1230.04014.59
5.3.240.1070.06014.53
5.3.230.0970.05714.57
5.3.220.1030.05714.54
5.3.210.0930.06014.53
5.3.200.0800.06714.51
5.3.190.0830.04714.49
5.3.180.0730.05314.48
5.3.170.0930.05714.55
5.3.160.0830.04714.55
5.3.150.0770.06014.59
5.3.140.0930.03714.46
5.3.130.0870.05014.54
5.3.120.0830.05314.46
5.3.110.0830.05314.62
5.3.100.0900.06014.07
5.3.90.1030.06314.02
5.3.80.1030.04713.97
5.3.70.1000.04713.93
5.3.60.1030.04314.08
5.3.50.0830.05313.91
5.3.40.0800.05713.89
5.3.30.0800.04713.86
5.3.20.0800.04713.77
5.3.10.0770.05313.59
5.3.00.0770.04713.63
5.2.170.0770.04011.29
5.2.160.0730.03711.10
5.2.150.0770.06011.18
5.2.140.0900.04311.07
5.2.130.0970.04311.07
5.2.120.0870.04311.13
5.2.110.0700.05311.03
5.2.100.0730.03011.16
5.2.90.0630.03711.09
5.2.80.0700.04311.25
5.2.70.0630.04711.23
5.2.60.0600.03711.01
5.2.50.0530.03711.07
5.2.40.0600.04310.95
5.2.30.0570.04310.95
5.2.20.0530.04010.90
5.2.10.0530.04711.01
5.2.00.0570.04310.72
5.1.60.0530.03710.11
5.1.50.0630.04010.04
5.1.40.0570.04010.10
5.1.30.0600.04310.47
5.1.20.0530.03710.50
5.1.10.0470.03310.17
5.1.00.0300.04310.05
5.0.50.0270.0238.64
5.0.40.0300.0338.52
5.0.30.0300.0438.23
5.0.20.0300.0338.30
5.0.10.0400.0308.22
5.0.00.0330.0408.12
4.4.90.0300.0235.84
4.4.80.0230.0235.91
4.4.70.0430.0275.89
4.4.60.0330.0135.92
4.4.50.0330.0275.92
4.4.40.0300.0505.89
4.4.30.0300.0405.90
4.4.20.0270.0335.90
4.4.10.0400.0175.98
4.4.00.0270.0335.98
4.3.110.0200.0205.88
4.3.100.0130.0235.82
4.3.90.0130.0335.81
4.3.80.0370.0405.82
4.3.70.0500.0305.85
4.3.60.0270.0235.84
4.3.50.0270.0275.85
4.3.40.0300.0335.80
4.3.30.0200.0204.57
4.3.20.0330.0304.67
4.3.10.0170.0304.50
4.3.00.0100.0207.02

preferences:
49.98 ms | 401 KiB | 5 Q