3v4l.org

run code in 300+ PHP versions simultaneously
<?php $value = 'Y-100;Y-10'; $arrvalidrules = explode(';', $value); // On vérifie qu'il n'y bien que deux valeurs. if (count($arrvalidrules) == 2) { $intyearend = null; if ($arrvalidrules[0]!='') { if (is_numeric($arrvalidrules[0])) { $intyearstart=intval($arrvalidrules[0]); } else if (strpos($arrvalidrules[0], 'Y') === 0) { $intyearstart = date('Y'); if (($intsignpos = strpos($arrvalidrules[0], '+')) !== false) { $intyearstart += intval(trim(substr($arrvalidrules[0], $intsignpos+1))); } else if (($intsignpos = strpos($arrvalidrules[0], '-')) !== false) { $intyearstart -= intval(trim(substr($arrvalidrules[0], $intsignpos+1))); } } else { $intyearstart = false; } } else { $intyearstart = 0; } } echo 'Date : '.$intyearstart.' - '.$intyearend;

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.0120.00618.30
8.3.50.0080.01117.49
8.3.40.0060.01318.93
8.3.30.0070.00718.79
8.3.20.0040.00418.79
8.3.10.0000.00920.61
8.3.00.0040.00419.34
8.2.180.0080.01118.30
8.2.170.0140.00022.96
8.2.160.0090.00619.13
8.2.150.0000.00924.18
8.2.140.0080.00024.66
8.2.130.0050.00226.16
8.2.120.0060.00320.46
8.2.110.0100.00021.11
8.2.100.0090.00317.81
8.2.90.0030.00619.43
8.2.80.0040.00419.43
8.2.70.0080.00017.63
8.2.60.0050.00317.91
8.2.50.0060.00318.07
8.2.40.0070.00018.41
8.2.30.0030.00718.25
8.2.20.0030.00619.64
8.2.10.0000.00817.70
8.2.00.0030.00617.89
8.1.280.0060.01325.92
8.1.270.0000.00823.99
8.1.260.0070.00026.35
8.1.250.0040.00428.09
8.1.240.0110.00020.82
8.1.230.0070.00320.97
8.1.220.0080.00017.77
8.1.210.0050.00318.77
8.1.200.0000.01017.48
8.1.190.0040.00417.54
8.1.180.0000.00818.10
8.1.170.0040.00418.84
8.1.160.0030.00519.03
8.1.150.0040.00418.79
8.1.140.0000.00717.54
8.1.130.0000.00717.96
8.1.120.0040.00417.51
8.1.110.0000.00717.64
8.1.100.0000.00717.59
8.1.90.0000.00817.58
8.1.80.0050.00217.59
8.1.70.0070.00017.55
8.1.60.0000.00817.61
8.1.50.0050.00317.43
8.1.40.0040.00417.57
8.1.30.0040.00417.64
8.1.20.0040.00417.63
8.1.10.0000.00717.55
8.1.00.0040.00417.66
8.0.300.0040.00419.89
8.0.290.0030.00616.75
8.0.280.0030.00518.43
8.0.270.0030.00718.07
8.0.260.0000.00817.00
8.0.250.0050.00317.14
8.0.240.0000.00717.00
8.0.230.0030.00517.13
8.0.220.0070.00017.05
8.0.210.0070.00016.95
8.0.200.0030.00317.04
8.0.190.0000.00717.00
8.0.180.0070.00016.98
8.0.170.0000.00816.82
8.0.160.0040.00416.95
8.0.150.0050.00316.97
8.0.140.0040.00416.89
8.0.130.0000.00513.43
8.0.120.0040.00416.90
8.0.110.0040.00416.93
8.0.100.0040.00416.77
8.0.90.0030.00516.95
8.0.80.0070.01417.01
8.0.70.0000.00816.77
8.0.60.0040.00416.84
8.0.50.0030.00616.93
8.0.30.0040.01417.21
8.0.20.0100.00817.20
8.0.10.0040.00417.20
8.0.00.0060.01516.75
7.4.330.0000.00613.08
7.4.320.0000.00616.71
7.4.300.0060.00016.59
7.4.290.0030.00316.60
7.4.280.0030.00516.68
7.4.270.0040.00416.55
7.4.260.0060.00013.30
7.4.250.0040.00416.67
7.4.240.0050.00216.74
7.4.230.0000.00716.51
7.4.220.0120.01216.67
7.4.210.0030.01316.73
7.4.200.0040.00416.62
7.4.190.0000.00816.83
7.4.160.0060.00916.60
7.4.150.0120.00616.66
7.4.140.0180.00016.49
7.4.130.0150.00816.83
7.4.120.0040.01216.47
7.4.110.0060.01216.63
7.4.100.0070.01016.54
7.4.90.0100.01616.51
7.4.80.0130.00319.39
7.4.70.0060.01016.65
7.4.60.0100.00616.43
7.4.50.0030.00616.50
7.4.40.0090.00616.51
7.4.30.0080.01216.73
7.4.00.0030.01315.13
7.3.330.0060.00013.25
7.3.320.0090.00013.29
7.3.310.0060.00316.55
7.3.300.0060.00016.25
7.3.290.0080.00716.39
7.3.280.0120.00416.30
7.3.270.0130.00416.54
7.3.260.0070.01016.32
7.3.250.0100.01216.53
7.3.240.0060.01016.57
7.3.230.0120.00916.49
7.3.210.0080.00816.63
7.3.200.0060.01616.50
7.3.190.0110.00916.58
7.3.180.0110.00516.61
7.3.170.0060.01016.67
7.3.160.0060.00916.59
7.3.120.0060.00914.86
7.2.330.0120.00616.93
7.2.320.0090.00916.61
7.2.310.0070.01116.96
7.2.300.0000.01616.63
7.2.290.0070.01016.81
7.2.00.0040.01119.70
7.1.100.0040.00818.09
7.1.70.0070.00017.30
7.1.60.0080.01119.17
7.1.50.0250.00734.89
7.1.00.0030.03322.57
7.0.200.0390.00414.90
7.0.140.0070.07022.09
7.0.120.0030.07322.17
7.0.80.0600.04720.02
7.0.70.0470.05319.95
7.0.60.0500.06319.88
7.0.50.0530.05320.29
7.0.40.0000.05020.04
7.0.30.0130.07320.02
7.0.20.0070.04320.04
7.0.10.0000.09020.17
7.0.00.0030.07020.13
5.6.280.0030.07321.12
5.6.230.0030.05320.63
5.6.220.0100.05320.50
5.6.210.0070.04020.66
5.6.200.0070.08021.11
5.6.190.0030.05721.03
5.6.180.0200.06321.08
5.6.170.0100.07021.14
5.6.160.0100.05321.07
5.6.150.0030.04721.11
5.6.140.0030.05321.04
5.6.130.0100.04020.96
5.6.120.0030.05321.04
5.6.110.0100.03721.08
5.6.100.0070.08320.95
5.6.90.0070.08721.02
5.6.80.0130.07320.44
5.6.70.0030.04720.35
5.6.60.0130.07320.47
5.6.50.0030.07020.44
5.6.40.0130.06720.36
5.6.30.0030.08320.46
5.6.20.0100.06020.44
5.6.10.0000.08320.49
5.6.00.0070.05320.45
5.5.370.0030.07320.37
5.5.360.0030.05320.39
5.5.350.0100.05020.45
5.5.340.0100.06020.81
5.5.330.0030.08320.93
5.5.320.0030.04320.83
5.5.310.0030.08020.73
5.5.300.0030.04320.89
5.5.290.0030.08720.88
5.5.280.0100.07720.89
5.5.270.0100.07320.90
5.5.260.0030.08020.88
5.5.250.0070.08320.66
5.5.240.0030.04320.25
5.5.230.0100.07320.15
5.5.220.0130.07320.30
5.5.210.0130.07020.24
5.5.200.0070.08320.13
5.5.190.0070.05320.15
5.5.180.0070.07720.18
5.5.160.0100.08020.09
5.5.150.0030.08320.25
5.5.140.0130.04720.18
5.5.130.0170.05720.24
5.5.120.0030.08720.25
5.5.110.0100.06319.99
5.5.100.0100.04719.98
5.5.90.0130.06319.97
5.5.80.0100.05719.98
5.5.70.0030.08320.07
5.5.60.0100.07720.04
5.5.50.0100.07020.00
5.5.40.0130.07020.05
5.5.30.0100.04719.99
5.5.20.0000.08720.14
5.5.10.0070.04720.13
5.5.00.0100.07320.00
5.4.450.0000.05019.44
5.4.440.0170.07019.27
5.4.430.0100.05019.44
5.4.420.0130.07319.55
5.4.410.0070.08019.29
5.4.400.0030.06018.98
5.4.390.0170.06719.09
5.4.380.0000.05319.09
5.4.370.0200.06718.81
5.4.360.0100.07718.95
5.4.350.0130.07319.14
5.4.340.0170.07018.79
5.4.320.0070.06319.12
5.4.310.0000.08319.06
5.4.300.0100.07318.81
5.4.290.0100.04019.14
5.4.280.0170.05018.97
5.4.270.0070.07319.07
5.4.260.0100.04718.96
5.4.250.0030.07318.96
5.4.240.0030.08019.11
5.4.230.0000.06319.02
5.4.220.0070.08019.09
5.4.210.0100.07318.90
5.4.200.0070.05719.11
5.4.190.0130.06719.24
5.4.180.0100.07019.10
5.4.170.0070.08018.80
5.4.160.0100.07319.07
5.4.150.0000.04719.10
5.4.140.0030.08016.34
5.4.130.0030.05016.43
5.4.120.0070.06316.17
5.4.110.0130.07016.49
5.4.100.0200.06316.31
5.4.90.0100.06016.23
5.4.80.0130.06716.43
5.4.70.0070.06716.42
5.4.60.0170.06016.38
5.4.50.0030.05716.25
5.4.40.0030.07716.46
5.4.30.0070.07016.31
5.4.20.0070.07316.22
5.4.10.0070.05716.27
5.4.00.0030.08015.71
5.3.290.0070.08014.68
5.3.280.0130.06314.54
5.3.270.0070.07714.57
5.3.260.0000.08014.45
5.3.250.0000.07714.52
5.3.240.0130.07314.48
5.3.230.0070.07014.61
5.3.220.0000.08714.54
5.3.210.0000.08014.54
5.3.200.0100.07314.44
5.3.190.0130.06714.43
5.3.180.0030.08714.55
5.3.170.0000.06314.43
5.3.160.0030.05014.45
5.3.150.0070.07314.48
5.3.140.0030.07014.41
5.3.130.0170.07014.41
5.3.120.0030.04314.41
5.3.110.0070.08014.56
5.3.100.0070.04713.90
5.3.90.0070.06313.86
5.3.80.0030.05014.03
5.3.70.0070.04013.98
5.3.60.0030.07313.92
5.3.50.0100.05713.91
5.3.40.0000.04313.95
5.3.30.0100.07313.91
5.3.20.0070.06313.64
5.3.10.0270.02713.42
5.3.00.0070.05013.41
5.2.170.0100.04711.19
5.2.160.0030.03311.20
5.2.150.0030.04011.02
5.2.140.0070.06311.00
5.2.130.0070.05010.92
5.2.120.0070.06011.11
5.2.110.0100.04710.94
5.2.100.0130.04311.11
5.2.90.0030.04011.14
5.2.80.0100.06011.13
5.2.70.0000.06011.09
5.2.60.0000.05311.09
5.2.50.0130.04010.95
5.2.40.0100.05710.93
5.2.30.0000.06710.98
5.2.20.0030.06010.96
5.2.10.0130.05011.00
5.2.00.0000.03310.78
5.1.60.0030.02310.06
5.1.50.0030.0279.99
5.1.40.0030.02710.09
5.1.30.0030.02710.43
5.1.20.0000.03010.42
5.1.10.0070.02710.11
5.1.00.0070.02010.11
5.0.50.0070.0238.44
5.0.40.0000.0208.41
5.0.30.0000.0378.36
5.0.20.0000.0208.36
5.0.10.0030.0178.36
5.0.00.0030.0308.36
4.4.90.0000.0378.36
4.4.80.0000.0378.36
4.4.70.0070.0138.36
4.4.60.0000.0178.36
4.4.50.0070.0108.36
4.4.40.0000.0278.36
4.4.30.0000.0208.36
4.4.20.0000.0208.36
4.4.10.0000.0178.36
4.4.00.0000.0278.36
4.3.110.0070.0108.36
4.3.100.0000.0178.36
4.3.90.0000.0178.36
4.3.80.0000.0278.36
4.3.70.0030.0138.36
4.3.60.0030.0108.36
4.3.50.0000.0178.36
4.3.40.0000.0238.36
4.3.30.0000.0208.36
4.3.20.0000.0178.36
4.3.10.0030.0138.36
4.3.00.0000.0138.36

preferences:
45.95 ms | 401 KiB | 5 Q