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 > < 1 2 ... 19 [20] 21 22 23 > < 1 2 ... 20 [21] 22 23 > < 1 2 ... 21 [22] 23 > < 1 2 ... 22 [23] > */ $currentpageid = $nmstart = 2; $nrtotal = 23; $nrposts = 1; $pages = ''; $ssPagingStartCount = 2; $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>"; } } */ //$ssPagingCurrentCountRight = max($ssPagingStartCount, ($currentpageid + (int)($ssPagingCurrentCount/2))); $ssPagingCurrentCountFrom = $currentpageid - (int)($ssPagingCurrentCount/2); if ( $ssPagingCurrentCountFrom < 0 ) $ssPagingCurrentCountFrom = 0; $ssPagingCurrentCountTo = $currentpageid + (int)($ssPagingCurrentCount/2); if ( $ssPagingCurrentCountTo > $totalpages ) $ssPagingCurrentCountTo = $totalpages; if ( ($currentpageid >= 0) && ($currentpageid < ($ssPagingStartCount + (int)($ssPagingCurrentCount/2))) ) { for ($x = 0; $x < $ssPagingCurrentCountTo; ++$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.0170.00316.63
8.3.50.0130.00821.98
8.3.40.0060.01018.84
8.3.30.0070.01018.89
8.3.20.0040.00420.25
8.3.10.0070.00721.89
8.3.00.0060.00319.38
8.2.180.0110.00716.50
8.2.170.0100.01022.96
8.2.160.0110.00419.29
8.2.150.0070.00724.18
8.2.140.0030.00524.66
8.2.130.0070.00326.16
8.2.120.0080.00019.77
8.2.110.0070.00321.18
8.2.100.0060.00617.63
8.2.90.0000.00819.36
8.2.80.0000.00817.97
8.2.70.0040.00417.75
8.2.60.0080.00018.05
8.2.50.0000.00918.07
8.2.40.0000.00819.94
8.2.30.0040.00418.22
8.2.20.0040.00417.65
8.2.10.0040.00418.12
8.2.00.0040.00417.65
8.1.280.0140.00725.92
8.1.270.0130.00720.79
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0030.00623.92
8.1.230.0080.00320.48
8.1.220.0080.00017.79
8.1.210.0040.00418.77
8.1.200.0040.00417.36
8.1.190.0060.00317.23
8.1.180.0040.00418.10
8.1.170.0030.00520.38
8.1.160.0040.00421.91
8.1.150.0040.00418.91
8.1.140.0000.00717.41
8.1.130.0000.00717.77
8.1.120.0000.00717.39
8.1.110.0040.00417.54
8.1.100.0040.00417.49
8.1.90.0070.00017.47
8.1.80.0000.00817.39
8.1.70.0000.00717.51
8.1.60.0000.00817.61
8.1.50.0040.00417.52
8.1.40.0000.00817.54
8.1.30.0000.00817.70
8.1.20.0040.00417.59
8.1.10.0040.00417.49
8.1.00.0040.00417.42
8.0.300.0040.00418.77
8.0.290.0040.00416.75
8.0.280.0000.00718.45
8.0.270.0040.00417.33
8.0.260.0070.00017.32
8.0.250.0030.00316.98
8.0.240.0000.00716.98
8.0.230.0000.00717.04
8.0.220.0040.00416.96
8.0.210.0040.00416.90
8.0.200.0000.00716.97
8.0.190.0040.00417.04
8.0.180.0040.00416.81
8.0.170.0000.00716.84
8.0.160.0000.00716.92
8.0.150.0030.00316.77
8.0.140.0000.00716.91
8.0.130.0000.00613.31
8.0.120.0050.00316.86
8.0.110.0070.00016.76
8.0.100.0020.00516.95
8.0.90.0000.00816.71
8.0.80.0030.01316.80
8.0.70.0080.00016.91
8.0.60.0040.00416.92
8.0.50.0000.00816.79
8.0.30.0090.01417.01
8.0.20.0140.00617.40
8.0.10.0050.00217.01
8.0.00.0080.00816.84
7.4.330.0020.00215.03
7.4.320.0060.00016.52
7.4.300.0090.00016.57
7.4.290.0070.00016.61
7.4.280.0030.00316.66
7.4.270.0000.00716.63
7.4.260.0000.00716.63
7.4.250.0060.00316.59
7.4.240.0000.00816.57
7.4.230.0040.00416.51
7.4.220.0060.01216.61
7.4.210.0030.01616.49
7.4.200.0030.00316.38
7.4.160.0080.00816.40
7.4.150.0090.00917.40
7.4.140.0110.00817.86
7.4.130.0080.00816.43
7.4.120.0100.00816.60
7.4.110.0150.00616.45
7.4.100.0100.00716.67
7.4.90.0090.00816.45
7.4.80.0100.00719.39
7.4.70.0080.00816.48
7.4.60.0060.01016.43
7.4.50.0020.00216.52
7.4.40.0040.01216.38
7.4.30.0110.01116.65
7.4.00.0030.00714.96
7.3.330.0000.00513.17
7.3.320.0090.00813.17
7.3.310.0000.00616.26
7.3.300.0060.00016.22
7.3.290.0040.01016.33
7.3.280.0080.00716.30
7.3.270.0090.00917.40
7.3.260.0100.01016.40
7.3.250.0080.01016.33
7.3.240.0090.00616.54
7.3.230.0110.00716.39
7.3.210.0080.00816.66
7.3.200.0130.00319.39
7.3.190.0080.01316.32
7.3.180.0090.00916.36
7.3.170.0120.00616.29
7.3.160.0120.00316.36
7.2.330.0100.00716.84
7.2.320.0090.00916.50
7.2.310.0060.00916.60
7.2.300.0120.00616.74
7.2.290.0090.00916.73
7.2.00.0070.00719.02
7.1.100.0070.01018.32
7.1.70.0060.00616.93
7.1.60.0100.01319.46
7.1.50.0100.01034.56
7.1.00.0000.08022.31
7.0.200.0030.00716.79
7.0.140.0070.03022.12
7.0.70.4930.04019.95
7.0.60.0070.07020.04
7.0.50.0070.05017.91
7.0.40.0100.05320.05
7.0.30.0200.07720.20
7.0.20.0370.07320.00
7.0.10.0330.07720.27
7.0.00.0030.07720.16
5.6.280.0000.07721.05
5.6.210.0230.06320.50
5.6.200.0130.04718.11
5.6.190.0070.08720.33
5.6.180.0200.03720.30
5.6.170.0270.05320.40
5.6.160.0030.07020.48
5.6.150.0000.09318.14
5.6.140.0130.07718.21
5.6.130.0130.07718.18
5.6.120.0100.08020.99
5.6.110.0000.07021.12
5.6.100.0100.08720.91
5.6.90.0130.07320.96
5.6.80.0100.04320.29
5.6.70.0270.06320.40
5.5.350.0100.07320.44
5.5.340.0070.08017.93
5.5.330.0070.08020.21
5.5.320.0000.05720.44
5.5.310.0300.03720.17
5.5.300.0030.07718.02
5.5.290.0130.05318.01
5.5.280.0030.08320.88
5.5.270.0030.05020.75
5.5.260.0070.05020.87
5.5.250.0100.04020.59
5.5.240.0070.07320.16
5.4.450.0500.05719.60
5.4.440.0330.04019.47
5.4.430.0130.06019.46
5.4.420.0170.05319.43
5.4.410.0230.05018.99
5.4.400.0230.04718.51
5.4.390.0230.05718.73
5.4.380.0200.05018.51
5.4.370.0270.04718.59
5.4.360.0130.06018.55
5.4.350.0230.04718.78
5.4.340.0170.05318.67
5.4.320.0130.05718.54
5.4.310.0130.05718.67
5.4.300.0100.06318.57
5.4.290.0170.05718.73
5.4.280.0130.05318.61
5.4.270.0100.05718.60
5.4.260.0200.04718.79
5.4.250.0030.06318.68
5.4.240.0100.06318.63
5.4.230.0170.06018.67
5.4.220.0070.06318.57
5.4.210.0170.05018.50
5.4.200.0170.04716.57
5.4.190.0230.04318.75
5.4.180.0170.05018.46
5.4.170.0130.06318.68
5.4.160.0170.05018.66
5.4.150.0130.07018.68
5.4.140.0170.05016.37
5.4.130.0130.05716.05
5.4.120.0130.05016.31
5.4.110.0130.06016.27
5.4.100.0100.06016.22
5.4.90.0170.05016.27
5.4.80.0100.05716.11
5.4.70.0100.06016.18
5.4.60.0070.05716.24
5.4.50.0200.05316.28
5.4.40.0070.05716.20
5.4.30.0170.04716.19
5.4.20.0100.05316.30
5.4.10.0230.04016.28
5.4.00.0170.04715.62
5.3.290.0130.06714.66
5.3.280.0130.05314.63
5.3.270.0170.05314.64
5.3.260.0170.05714.62
5.3.250.0200.05314.70
5.3.240.0100.06014.69
5.3.230.0230.04714.59
5.3.220.0200.04714.58
5.3.210.0130.06314.50
5.3.200.0130.05314.49
5.3.190.0170.05014.57
5.3.180.0130.05014.52
5.3.170.0200.05314.67
5.3.160.0100.05314.57
5.3.150.0130.05314.67
5.3.140.0130.05014.54
5.3.130.0070.06014.52
5.3.120.0070.06314.61
5.3.110.0130.05714.49
5.3.100.0170.05314.00
5.3.90.0170.05014.04
5.3.80.0130.05314.02
5.3.70.0130.05714.02
5.3.60.0100.05313.99
5.3.50.0070.06313.89
5.3.40.0100.05313.94
5.3.30.0170.05313.91
5.3.20.0100.05713.67
5.3.10.0170.04313.66
5.3.00.0270.05013.63
5.2.170.0100.04711.18
5.2.160.0270.04011.14
5.2.150.0130.04311.11
5.2.140.0130.04711.06
5.2.130.0070.04311.17
5.2.120.0070.04311.16
5.2.110.0130.04011.08
5.2.100.0100.05011.03
5.2.90.0170.03711.16
5.2.80.0200.03311.05
5.2.70.0100.04311.02
5.2.60.0100.04311.12
5.2.50.0130.04010.98
5.2.40.0170.04711.06
5.2.30.0200.03010.89
5.2.20.0100.04310.92
5.2.10.0100.03710.84
5.2.00.0130.03710.71
5.1.60.0070.03710.04
5.1.50.0170.02710.08
5.1.40.0170.03310.01
5.1.30.0030.05010.54
5.1.20.0100.03710.41
5.1.10.0070.03710.27
5.1.00.0070.04010.12
5.0.50.0030.0308.59
5.0.40.0030.0308.54
5.0.30.0030.0508.32
5.0.20.0070.0278.32
5.0.10.0130.0208.20
5.0.00.0100.0408.21
4.4.90.0070.0206.02
4.4.80.0030.0235.92
4.4.70.0070.0205.92
4.4.60.0030.0236.00
4.4.50.0000.0275.84
4.4.40.0100.0305.87
4.4.30.0070.0205.94
4.4.20.0070.0205.99
4.4.10.0130.0205.99
4.4.00.0030.0375.99
4.3.110.0030.0275.88
4.3.100.0100.0235.78
4.3.90.0130.0135.80
4.3.80.0070.0335.83
4.3.70.0000.0275.93
4.3.60.0070.0205.88
4.3.50.0070.0235.89
4.3.40.0000.0405.77
4.3.30.0070.0204.68
4.3.20.0030.0234.55
4.3.10.0030.0234.50
4.3.00.0100.0237.02

preferences:
44 ms | 401 KiB | 5 Q