3v4l.org

run code in 300+ PHP versions simultaneously
<?php $start = (new DateTime('1 year ago'))->modify('first day of this month'); $end = (new DateTime())->modify('first day of this month'); $interval = new DateInterval('P1M'); $period = new DatePeriod($start, $interval, $end); $months = array(); foreach ($period as $dt) { $months[] = $dt->format('Y-m-d'); } $reverse_months = array_reverse($months); print_r($reverse_months);

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.0060.00918.64
8.3.50.0160.00622.05
8.3.40.0040.01519.06
8.3.30.0070.00719.20
8.3.20.0000.00820.13
8.3.10.0000.00822.04
8.3.00.0040.00422.39
8.2.180.0150.00618.38
8.2.170.0090.00622.96
8.2.160.0110.00321.02
8.2.150.0080.00024.18
8.2.140.0040.00424.66
8.2.130.0070.01026.16
8.2.120.0040.00419.49
8.2.110.0060.00320.52
8.2.100.0060.00619.75
8.2.90.0000.00919.33
8.2.80.0080.00017.97
8.2.70.0050.00318.00
8.2.60.0060.00618.05
8.2.50.0030.00718.07
8.2.40.0000.00818.34
8.2.30.0030.00718.35
8.2.20.0040.00418.08
8.2.10.0080.00018.16
8.2.00.0040.00418.05
8.1.280.0100.00725.92
8.1.270.0000.00822.20
8.1.260.0040.00426.35
8.1.250.0000.00828.09
8.1.240.0030.00622.32
8.1.230.0100.00317.71
8.1.220.0000.00817.78
8.1.210.0050.00318.77
8.1.200.0100.00317.61
8.1.190.0000.00817.55
8.1.180.0040.00418.90
8.1.170.0000.01018.79
8.1.160.0070.00022.17
8.1.150.0060.00318.90
8.1.140.0040.00417.73
8.1.130.0000.00817.85
8.1.120.0030.00717.73
8.1.110.0030.00517.62
8.1.100.0040.00417.64
8.1.90.0000.00817.63
8.1.80.0030.00617.73
8.1.70.0040.00417.73
8.1.60.0080.00017.77
8.1.50.0040.00417.76
8.1.40.0050.00317.63
8.1.30.0050.00317.86
8.1.20.0030.00617.85
8.1.10.0000.00817.72
8.1.00.0080.00017.83
8.0.300.0040.00418.77
8.0.290.0050.00217.00
8.0.280.0030.00318.66
8.0.270.0000.00717.11
8.0.260.0050.00317.02
8.0.250.0000.00717.20
8.0.240.0050.00317.27
8.0.230.0040.00417.30
8.0.220.0070.00017.04
8.0.210.0070.00017.02
8.0.200.0000.00617.20
8.0.190.0060.00317.13
8.0.180.0000.00717.13
8.0.170.0070.00017.20
8.0.160.0030.00517.14
8.0.150.0000.00717.10
8.0.140.0040.00417.16
8.0.130.0000.00513.48
8.0.120.0060.00317.15
8.0.110.0040.00417.12
8.0.100.0000.01017.08
8.0.90.0000.00717.18
8.0.80.0180.00317.10
8.0.70.0040.00417.07
8.0.60.0040.00317.09
8.0.50.0000.00716.98
8.0.30.0080.01017.33
8.0.20.0060.01217.54
8.0.10.0000.00817.35
8.0.00.0100.00816.98
7.4.330.0030.00315.10
7.4.320.0030.00316.72
7.4.300.0020.00516.74
7.4.290.0030.00516.84
7.4.280.0000.00816.83
7.4.270.0060.00316.77
7.4.260.0030.00316.77
7.4.250.0040.00416.60
7.4.240.0040.00316.77
7.4.230.0040.00416.58
7.4.220.0060.01116.72
7.4.210.0080.00716.85
7.4.200.0050.00216.79
7.4.190.0030.00316.65
7.4.160.0060.00916.71
7.4.150.0100.00717.40
7.4.140.0080.01217.86
7.4.130.0110.01016.75
7.4.120.0110.00816.88
7.4.110.0070.01016.70
7.4.100.0120.01416.80
7.4.90.0140.00416.97
7.4.80.0120.00919.39
7.4.70.0040.01216.68
7.4.60.0130.01416.81
7.4.50.0040.00416.61
7.4.40.0060.00622.77
7.4.30.0060.01016.57
7.4.00.0070.00715.16
7.3.330.0000.00513.35
7.3.320.0030.00313.38
7.3.310.0030.00316.43
7.3.300.0000.00716.50
7.3.290.0030.01116.49
7.3.280.0110.00516.47
7.3.270.0100.00717.40
7.3.260.0090.00916.89
7.3.250.0060.01316.69
7.3.240.0030.01316.47
7.3.230.0160.00416.76
7.3.210.0100.01316.85
7.3.200.0130.00319.39
7.3.190.0170.00316.58
7.3.180.0030.01216.64
7.3.170.0100.01316.65
7.3.160.0060.00916.58
7.3.120.0100.00615.08
7.2.330.0070.01016.98
7.2.320.0070.01416.64
7.2.310.0060.01316.84
7.2.300.0140.00316.97
7.2.290.0100.00616.72
7.2.60.0090.00317.10
7.2.00.0040.00819.83
7.1.200.0030.00715.75
7.1.100.0060.00618.16
7.1.70.0020.00517.39
7.1.60.0070.01419.82
7.1.50.0000.01017.21
7.1.00.0030.07722.34
7.0.200.0090.00317.11
7.0.140.0000.07721.92
7.0.110.0570.06719.98
7.0.100.0530.05720.07
7.0.90.0470.04720.04
7.0.80.0470.04019.91
7.0.70.0270.04319.91
7.0.60.0400.04020.05
7.0.50.0500.04019.86
7.0.40.0030.04019.84
7.0.30.0070.04719.65
7.0.20.0000.04319.65
7.0.10.0070.03719.74
7.0.00.0030.05019.84
5.6.280.0000.07721.13
5.6.260.0100.03720.65
5.6.250.0030.08020.69
5.6.240.0070.05320.71
5.6.230.0100.04320.56
5.6.220.0000.04320.62
5.6.210.0030.05320.80
5.6.200.0000.03720.56
5.6.190.0000.03720.85
5.6.180.0070.04320.85
5.6.170.0100.03320.64
5.6.160.0070.03720.61
5.6.150.0170.03020.65
5.6.140.0070.08320.70
5.6.130.0070.04320.55
5.6.120.0000.04720.64
5.6.110.0130.04320.55
5.6.100.0070.07020.59
5.6.90.0070.05020.65
5.6.80.0030.04319.96
5.6.70.0030.04020.07
5.6.60.0070.03020.01
5.6.50.0070.05020.04
5.6.40.0100.07320.07
5.6.30.0030.08019.91
5.6.20.0070.03719.98
5.6.10.0000.04319.96
5.6.00.0100.05019.91
5.5.380.0030.05017.59
5.5.370.0100.06317.70
5.5.360.0070.06017.68
5.5.350.0000.04317.48
5.5.340.0000.06017.91
5.5.330.0070.04718.27
5.5.320.0100.07717.82
5.5.310.0100.09018.22
5.5.300.0070.06717.91
5.5.290.0070.03317.83
5.5.280.0000.04317.93
5.5.270.0070.03318.22
5.5.260.0030.05717.82
5.5.250.0070.04717.72
5.5.240.0000.06017.62
5.5.230.0030.03317.60
5.5.220.0000.04017.30
5.5.210.0030.03717.50
5.5.200.0100.06717.27
5.5.190.0000.04317.45
5.5.180.0100.06717.47
5.5.160.0030.04017.25
5.5.150.0000.06717.57
5.5.140.0030.05717.57
5.5.130.0000.04717.60
5.5.120.0070.06017.25
5.5.110.0070.04717.41
5.5.100.0100.07017.47
5.5.90.0030.08017.18
5.5.80.0130.06317.15
5.5.70.0070.04317.07
5.5.60.0100.04317.36
5.5.50.0130.07017.18
5.5.40.0030.03317.17
5.5.30.0030.06717.49
5.5.20.0070.03717.45
5.5.10.0000.08017.36
5.5.00.0030.07717.14
5.4.450.0070.04019.49
5.4.440.0130.06719.32
5.4.430.0100.07019.33
5.4.420.0030.03319.50
5.4.410.0100.03019.21
5.4.400.0070.06718.98
5.4.390.0130.07019.02
5.4.380.0100.03319.01
5.4.370.0070.04018.98
5.4.360.0170.06319.14
5.4.350.0070.04018.95
5.4.340.0000.05719.01
5.4.320.0100.06019.23
5.4.310.0030.06719.03
5.4.300.0000.04019.20
5.4.290.0000.07319.13
5.4.280.0070.07319.23
5.4.270.0100.07019.13
5.4.260.0070.06019.14
5.4.250.0030.04019.00
5.4.240.0100.07718.99
5.4.230.0070.07019.15
5.4.220.0030.04018.98
5.4.210.0030.05019.17
5.4.200.0000.09019.17
5.4.190.0100.07019.32
5.4.180.0100.05018.93
5.4.170.0070.03019.14
5.4.160.0130.06718.93
5.4.150.0100.03319.16
5.4.140.0100.07016.56
5.4.130.0170.04716.47
5.4.120.0130.06316.59
5.4.110.0070.07316.61
5.4.100.0030.06016.36
5.4.90.0000.04716.37
5.4.80.0070.05016.54
5.4.70.0070.05316.45
5.4.60.0070.04316.44
5.4.50.0000.04716.28
5.4.40.0100.07316.44
5.4.30.0070.03716.54
5.4.20.0100.04016.56
5.4.10.0030.07716.47
5.4.00.0070.05316.07
5.3.290.0030.07714.57
5.3.280.0000.06014.70
5.3.270.0170.07014.47
5.3.260.0030.07314.63
5.3.250.0100.04314.45
5.3.240.0030.07714.70
5.3.230.0070.06014.52
5.3.220.0030.04314.56
5.3.210.0030.04014.42
5.3.200.0070.06714.36
5.3.190.0070.06714.52
5.3.180.0100.06714.45
5.3.170.0030.05314.49
5.3.160.0030.04014.44
5.3.150.0100.07314.50
5.3.140.0070.05014.50
5.3.130.0030.05314.38
5.3.120.0100.07314.45
5.3.110.0070.07714.49
5.3.100.0130.03313.99
5.3.90.0000.04013.92
5.3.80.0070.03313.86
5.3.70.0070.03313.86
5.3.60.0030.04013.95
5.3.50.0030.04313.82
5.3.40.0000.04313.88
5.3.30.0100.03013.98
5.3.20.0070.05313.59
5.3.10.0070.05013.56
5.3.00.0030.04713.57
5.2.170.0030.03012.06
5.2.160.0030.03012.06
5.2.150.0070.02712.06
5.2.140.0030.02312.06
5.2.130.0000.03012.06
5.2.120.0070.02012.06
5.2.110.0030.05012.06
5.2.100.0070.02712.06
5.2.90.0000.03012.06
5.2.80.0030.02312.06
5.2.70.0070.02712.06
5.2.60.0030.04012.06
5.2.50.0070.04012.06
5.2.40.0030.04312.06
5.2.30.0030.06012.06
5.2.20.0000.03012.06
5.2.10.0030.03012.06
5.2.00.0030.02712.06
5.1.60.0000.03012.06
5.1.50.0000.05012.06
5.1.40.0100.03312.06
5.1.30.0070.05312.06
5.1.20.0030.03712.06
5.1.10.0000.02712.06
5.1.00.0030.02012.06
5.0.50.0070.03012.06
5.0.40.0000.02012.06
5.0.30.0000.03312.06
5.0.20.0000.02012.06
5.0.10.0070.03712.06
5.0.00.0030.03712.06
4.4.90.0070.02712.06
4.4.80.0000.01312.06
4.4.70.0030.02012.06
4.4.60.0000.02312.06
4.4.50.0030.01312.06
4.4.40.0000.02312.06
4.4.30.0000.02712.06
4.4.20.0000.01312.06
4.4.10.0000.01712.06
4.4.00.0000.02712.06
4.3.110.0000.01712.06
4.3.100.0000.03312.06
4.3.90.0000.01712.06
4.3.80.0000.04712.06
4.3.70.0000.01712.06
4.3.60.0000.01712.06
4.3.50.0000.01712.06
4.3.40.0000.05012.06
4.3.30.0000.02312.06
4.3.20.0000.02312.06
4.3.10.0000.02312.06
4.3.00.0000.02012.06

preferences:
41.42 ms | 401 KiB | 5 Q