3v4l.org

run code in 300+ PHP versions simultaneously
<?php date_default_timezone_set('UTC'); $today = new DateTime; //to be sure that DateInterval will work as intended //we take the first day of the month $fist_day_of_the_month = $today->format('Y-m-01'); $range = new DatePeriod( new DateTime($fist_day_of_the_month), //begin new DateInterval('P1M'), //interval new DateTime($fist_day_of_the_month.' +24 month') //end ); foreach ($range as $date) { echo $date->format('Y-m-d'), PHP_EOL; }

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.0070.01418.55
8.3.50.0100.01022.05
8.3.40.0110.00418.97
8.3.30.0100.01019.09
8.3.20.0080.00020.18
8.3.10.0080.00021.92
8.3.00.0050.00322.34
8.2.180.0130.00316.88
8.2.170.0080.00822.96
8.2.160.0120.00320.86
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0150.00426.16
8.2.120.0040.00417.75
8.2.110.0030.00622.26
8.2.100.0060.00617.78
8.2.90.0040.00419.22
8.2.80.0040.00418.05
8.2.70.0030.00617.75
8.2.60.0040.00417.93
8.2.50.0040.00418.07
8.2.40.0040.00418.28
8.2.30.0000.00718.12
8.2.20.0030.00517.79
8.2.10.0040.00417.87
8.2.00.0000.00817.81
8.1.280.0160.00025.92
8.1.270.0030.00622.17
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0060.00318.75
8.1.230.0100.00019.14
8.1.220.0080.00017.77
8.1.210.0000.00818.77
8.1.200.0000.00817.48
8.1.190.0000.00817.41
8.1.180.0000.00818.63
8.1.170.0030.00518.61
8.1.160.0050.00322.07
8.1.150.0040.00418.71
8.1.140.0000.00917.71
8.1.130.0050.00317.69
8.1.120.0030.00317.67
8.1.110.0000.00717.55
8.1.100.0050.00317.55
8.1.90.0040.00417.68
8.1.80.0000.00717.70
8.1.70.0030.00317.53
8.1.60.0080.00017.74
8.1.50.0000.00817.64
8.1.40.0070.00017.68
8.1.30.0000.00717.67
8.1.20.0040.00417.66
8.1.10.0040.00417.68
8.1.00.0040.00417.67
8.0.300.0040.00418.77
8.0.290.0040.00417.05
8.0.280.0040.00418.39
8.0.270.0030.00317.38
8.0.260.0040.00417.02
8.0.250.0050.00317.18
8.0.240.0070.00017.16
8.0.230.0030.00617.17
8.0.220.0050.00217.08
8.0.210.0040.00417.11
8.0.200.0060.00017.01
8.0.190.0000.00717.07
8.0.180.0030.00317.07
8.0.170.0040.00417.12
8.0.160.0040.00417.14
8.0.150.0080.00017.11
8.0.140.0040.00417.05
8.0.130.0000.00513.57
8.0.120.0000.00817.08
8.0.110.0050.00317.13
8.0.100.0080.00017.15
8.0.90.0070.00017.03
8.0.80.0040.01117.05
8.0.70.0000.00916.96
8.0.60.0040.00417.10
8.0.50.0070.00017.17
8.0.30.0090.01117.39
8.0.20.0110.00917.40
8.0.10.0080.00017.10
8.0.00.0110.00916.94
7.4.330.0050.00015.00
7.4.320.0060.00016.54
7.4.300.0060.00016.74
7.4.290.0080.00016.66
7.4.280.0030.00316.64
7.4.270.0040.00416.74
7.4.260.0000.00816.62
7.4.250.0000.00716.52
7.4.240.0010.00616.65
7.4.230.0000.00716.48
7.4.220.0090.00916.53
7.4.210.0080.00616.73
7.4.200.0030.00316.80
7.4.190.0070.00016.81
7.4.160.0110.00716.57
7.4.150.0150.00417.40
7.4.140.0090.01017.86
7.4.130.0100.01116.72
7.4.120.0090.00916.66
7.4.110.0210.00016.68
7.4.100.0120.00616.67
7.4.90.0140.00616.45
7.4.80.0040.01419.39
7.4.70.0120.00616.55
7.4.60.0150.00416.76
7.4.50.0060.00316.41
7.4.40.0120.00622.77
7.4.30.0090.01216.86
7.4.00.0060.00915.20
7.3.330.0030.00313.21
7.3.320.0000.00513.20
7.3.310.0050.00316.43
7.3.300.0030.00316.48
7.3.290.0200.00016.41
7.3.280.0110.00716.45
7.3.270.0110.00717.40
7.3.260.0060.01216.52
7.3.250.0160.00716.63
7.3.240.0070.01516.31
7.3.230.0080.00916.42
7.3.210.0140.00416.73
7.3.200.0090.01419.39
7.3.190.0120.00616.50
7.3.180.0030.01216.31
7.3.170.0030.02016.57
7.3.160.0180.00616.45
7.3.120.0070.00714.96
7.3.10.0110.00817.04
7.3.00.0060.01116.79
7.2.330.0140.00416.83
7.2.320.0100.00716.69
7.2.310.0040.01817.07
7.2.300.0060.01016.73
7.2.290.0060.01616.71
7.2.130.0060.00817.04
7.2.120.0120.00916.80
7.2.110.0110.01117.04
7.2.100.0120.01016.76
7.2.90.0140.00816.98
7.2.80.0060.01516.84
7.2.70.0100.01317.11
7.2.60.0090.00517.04
7.2.50.0090.00716.78
7.2.40.0050.01217.07
7.2.30.0060.01116.89
7.2.20.0130.00616.82
7.2.10.0060.00617.05
7.2.00.0060.00717.22
7.1.250.0030.01215.91
7.1.240.0090.00615.86
7.1.230.0060.00615.75
7.1.220.0060.00615.71
7.1.210.0110.01115.91
7.1.200.0060.00415.70
7.1.190.0050.00515.99
7.1.180.0070.00715.84
7.1.170.0000.01415.93
7.1.160.0140.00716.00
7.1.150.0080.00715.75
7.1.140.0080.00815.98
7.1.130.0000.01415.71
7.1.120.0090.00915.61
7.1.110.0050.01216.07
7.1.100.0080.00617.03
7.1.90.0070.00715.83
7.1.80.0100.00315.66
7.1.70.0070.00916.67
7.1.60.0110.00517.80
7.1.50.0090.00316.52
7.1.40.0000.01416.08
7.1.30.0040.00915.98
7.1.20.0110.00715.98
7.1.10.0110.00515.93
7.1.00.0060.04119.19
7.0.330.0060.01015.45
7.0.320.0030.01215.38
7.0.310.0120.00315.59
7.0.300.0030.00915.54
7.0.290.0090.00915.31
7.0.280.0130.00015.14
7.0.270.0110.00415.24
7.0.260.0030.00715.23
7.0.250.0140.00415.41
7.0.240.0090.00315.29
7.0.230.0070.00515.75
7.0.220.0000.01415.44
7.0.210.0130.00415.63
7.0.200.0040.00616.13
7.0.190.0070.00715.21
7.0.180.0070.00615.48
7.0.170.0090.00615.49
7.0.160.0120.00315.48
7.0.150.0040.00915.43
7.0.140.0060.04218.75
7.0.130.0030.01315.42
7.0.120.0040.00815.55
7.0.110.0170.00715.62
7.0.100.0080.00515.55
7.0.90.0030.01415.50
7.0.80.0080.00815.37
7.0.70.0030.01015.48
7.0.60.0100.04017.65
7.0.50.0080.02116.82
7.0.40.0070.04916.79
7.0.30.0210.02616.61
7.0.20.0160.04316.65
7.0.10.0050.03816.82
7.0.00.0080.02116.76
5.6.380.0080.00414.07
5.6.370.0050.00914.20
5.6.360.0070.00814.39
5.6.350.0070.00714.58
5.6.340.0080.01114.48
5.6.330.0070.00714.43
5.6.320.0160.00414.18
5.6.310.0070.01314.29
5.6.300.0050.01014.18
5.6.290.0120.00214.22
5.6.280.0040.04117.61
5.6.270.0070.00914.04
5.6.260.0090.00914.52
5.6.250.0110.00714.66
5.6.240.0090.00614.61
5.6.230.0060.00914.60
5.6.220.0070.01014.47
5.6.210.0100.03017.30
5.6.200.0150.02116.30
5.6.190.0090.02217.49
5.6.180.0210.02317.47
5.6.170.0170.04617.54
5.6.160.0060.03017.38
5.6.150.0050.04516.36
5.6.140.0020.04516.15
5.6.130.0050.03816.23
5.6.120.0140.03117.64
5.6.110.0070.02317.52
5.6.100.0120.03917.81
5.6.90.0110.04017.76
5.6.80.0110.03417.47
5.6.70.0120.00913.95
5.6.60.0180.00014.57
5.6.50.0110.00813.96
5.6.40.0000.01414.14
5.6.30.0220.00613.90
5.6.20.0200.00914.21
5.6.10.0170.00414.03
5.6.00.0160.00414.04
5.5.380.0000.01111.20
5.5.370.0040.00911.27
5.5.360.0120.00311.17
5.5.350.2020.02815.81
5.5.340.0090.02514.38
5.5.330.0050.03015.52
5.5.320.0270.03815.68
5.5.310.0100.02515.65
5.5.300.0110.02514.52
5.5.290.0080.03314.50
5.5.280.0030.03515.85
5.5.270.0100.03015.99
5.5.260.0060.04615.99
5.5.250.0050.03415.74
5.5.240.0090.03215.59
5.5.230.0080.00510.85
5.5.220.0000.01411.13
5.5.210.0100.00510.52
5.5.200.0080.00510.91
5.5.190.0120.01211.29
5.5.180.0030.01011.08
5.5.170.0030.00311.01
5.5.160.0200.00310.71
5.5.150.0140.00010.85
5.5.140.0050.00510.87
5.5.130.0040.00710.81
5.5.120.0080.00410.91
5.5.110.0070.00410.91
5.5.100.0170.00010.55
5.5.90.0140.00410.85
5.5.80.0040.00710.68
5.5.70.0100.00511.17
5.5.60.0030.01011.04
5.5.50.0090.01310.94
5.5.40.0180.00010.76
5.5.30.0140.00011.15
5.5.20.0100.00311.06
5.5.10.0090.00910.54
5.5.00.0030.00610.85
5.4.450.0230.04015.20
5.4.440.0580.02415.26
5.4.430.0170.03215.09
5.4.420.0370.02815.25
5.4.410.0430.02714.86
5.4.400.0460.02714.82
5.4.390.0410.02614.95
5.4.380.0110.03114.75
5.4.370.0150.03014.66
5.4.360.0150.02714.88
5.4.350.0160.03014.55
5.4.340.0170.03114.64
5.4.330.0000.00811.22
5.4.320.0060.02211.77
5.4.310.0060.02611.59
5.4.300.0020.02211.61
5.4.290.0090.02011.69
5.4.280.0070.02011.72
5.4.270.0040.02211.65
5.4.260.0100.02514.93
5.4.250.0110.02514.91
5.4.240.0100.02314.75
5.4.230.0110.03914.97
5.4.220.0060.02914.95
5.4.210.0050.03014.87
5.4.200.0050.03014.84
5.4.190.0080.03014.84
5.4.180.0060.02614.82
5.4.170.0090.02515.00
5.4.160.0070.03214.74
5.4.150.0110.03615.05
5.4.140.0050.04113.64
5.4.130.0060.02413.65
5.4.120.0110.02313.79
5.4.110.0130.02113.68
5.4.100.0020.03013.69
5.4.90.0070.02513.63
5.4.80.0070.02813.57
5.4.70.0110.02513.73
5.4.60.0080.02313.60
5.4.50.0110.03313.51
5.4.40.0110.02513.73
5.4.30.0060.02713.55
5.4.20.0120.03013.59
5.4.10.0070.02713.66
5.4.00.0080.02513.33
5.3.290.0080.02311.65
5.3.280.0120.03012.51
5.3.270.0110.03612.65
5.3.260.0100.02512.58
5.3.250.0050.02712.60
5.3.240.0100.02712.49
5.3.230.0050.04012.44
5.3.220.0030.02812.42
5.3.210.0020.03312.38
5.3.200.0070.02712.49
5.3.190.0050.02812.44
5.3.180.0080.03212.49
5.3.170.0080.02612.61
5.3.160.0050.02812.47
5.3.150.0090.03712.58
5.3.140.0080.03812.46
5.3.130.0030.03312.57
5.3.120.0030.03012.55
5.3.110.0060.02812.51
5.3.100.0040.03412.20
5.3.90.0070.02712.12
5.3.80.0030.02812.04
5.3.70.0070.03512.04
5.3.60.0070.02712.14
5.3.50.0080.02712.28
5.3.40.0060.02612.31
5.3.30.0100.02212.13
5.3.20.0000.03512.01
5.3.10.0030.02911.92
5.3.00.0050.02711.94
5.2.170.0070.03010.31
5.2.160.0050.02810.35
5.2.150.0070.02010.43
5.2.140.0030.02310.39
5.2.130.0090.01710.26
5.2.120.0100.01810.26
5.2.110.0060.02310.18
5.2.100.0070.02110.26
5.2.90.0050.02310.20
5.2.80.0070.02310.11
5.2.70.0070.02810.20
5.2.60.0060.01810.13
5.2.50.0070.02010.21
5.2.40.0070.02010.08
5.2.30.0090.01910.20
5.2.20.0030.02210.22
5.2.10.0020.02410.11
5.2.00.0030.02410.00
5.1.60.0050.0239.15
5.1.50.0010.0219.20
5.1.40.0020.0229.24
5.1.30.0080.0179.47
5.1.20.0090.0159.40
5.1.10.0090.0189.34
5.1.00.0030.0219.18
5.0.50.0050.0158.24
5.0.40.0050.0158.23
5.0.30.0040.0228.17
5.0.20.0020.0158.17
5.0.10.0020.0178.20
5.0.00.0030.0248.21
4.4.90.0030.0177.81
4.4.80.0020.0137.81
4.4.70.0060.0117.81
4.4.60.0030.0137.81
4.4.50.0000.0147.81
4.4.40.0000.0227.81
4.4.30.0020.0137.81
4.4.20.0020.0127.81
4.4.10.0050.0107.81
4.4.00.0000.0207.81
4.3.110.0000.0147.81
4.3.100.0040.0097.81
4.3.90.0020.0127.81
4.3.80.0030.0167.81
4.3.70.0020.0117.81
4.3.60.0000.0137.81
4.3.50.0070.0107.81
4.3.40.0020.0197.81
4.3.30.0030.0137.81
4.3.20.0020.0157.81
4.3.10.0000.0187.81
4.3.00.0000.00910.69

preferences:
44.8 ms | 401 KiB | 5 Q