3v4l.org

run code in 300+ PHP versions simultaneously
<?php $month = 4; $monthName = date('M', strtotime('2012-'.$month.'-01')); $from = strtotime('first day of '.$monthName); if ( $from < time() ) { $from = strtotime('first day of '.$monthName.' '.(date('Y')+1)); } $to = strtotime('last day of this month, 23:59:59', $from); echo date('d.m.Y H:i:s', $from)."\r\n"; echo date('d.m.Y H:i:s', $to)."\r\n";

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)
7.4.10.0100.00815.21
7.4.00.0100.00715.20
7.3.130.0070.00815.11
7.3.120.0050.01015.21
7.3.110.0050.01414.95
7.3.100.0050.00815.05
7.3.90.0050.01015.15
7.3.80.0060.00614.99
7.3.70.0050.00714.89
7.3.60.0070.00715.06
7.3.50.0030.01014.83
7.3.40.0020.00814.90
7.3.30.0030.01315.17
7.3.20.0080.00616.63
7.3.10.0080.00616.97
7.3.00.0070.00616.82
7.2.260.0090.00915.27
7.2.250.0090.01015.36
7.2.240.0060.00815.46
7.2.230.0060.01015.39
7.2.220.0050.00715.55
7.2.210.0050.00815.24
7.2.200.0050.00715.39
7.2.190.0070.01015.36
7.2.180.0020.01315.31
7.2.170.0080.00715.29
7.2.160.0070.00615.31
7.2.150.0060.00917.19
7.2.140.0130.00017.15
7.2.130.0020.00717.26
7.2.120.0030.00917.25
7.2.110.0030.01317.13
7.2.100.0030.00916.95
7.2.90.0030.01017.05
7.2.80.0050.01117.17
7.2.70.0060.00617.21
7.2.60.0050.00917.12
7.2.50.0090.00517.25
7.2.40.0050.00917.23
7.2.30.0050.00817.13
7.2.20.0030.00717.08
7.2.10.0060.00617.21
7.2.00.0070.00717.92
7.1.330.0090.00416.16
7.1.320.0060.00616.20
7.1.310.0060.00615.89
7.1.300.0020.01416.03
7.1.290.0070.00415.98
7.1.280.0020.00815.90
7.1.270.0040.01115.84
7.1.260.0030.00915.90
7.1.250.0060.00515.95
7.1.240.0020.01216.15
7.1.230.0030.01015.99
7.1.220.0050.01015.86
7.1.210.0070.00715.93
7.1.200.0080.00615.96
7.1.190.0020.01015.95
7.1.180.0050.00815.89
7.1.170.0050.00816.13
7.1.160.0070.00816.04
7.1.150.0010.01216.01
7.1.140.0080.00515.93
7.1.130.0030.01016.03
7.1.120.0080.00616.01
7.1.110.0030.01115.99
7.1.100.0040.00616.75
7.1.90.0030.00816.08
7.1.80.0090.00415.95
7.1.70.0070.00616.54
7.1.60.0040.00816.58
7.1.50.0050.00716.53
7.1.40.0020.01316.08
7.1.30.0130.00116.14
7.1.20.0040.00915.97
7.1.10.0090.00416.11
7.1.00.0050.02718.09
7.0.330.0050.00715.53
7.0.320.0020.00915.54
7.0.310.0060.00815.64
7.0.300.0050.00915.46
7.0.290.0070.00415.45
7.0.280.0060.00715.51
7.0.270.0040.00815.62
7.0.260.0070.00515.66
7.0.250.0060.00415.69
7.0.240.0030.01215.64
7.0.230.0050.00515.70
7.0.220.0060.00715.70
7.0.210.0080.00515.58
7.0.200.0050.00816.05
7.0.190.0030.00915.78
7.0.180.0050.00815.56
7.0.170.0120.00215.46
7.0.160.0060.00515.67
7.0.150.0040.00615.48
7.0.140.0080.02517.63
7.0.130.0070.00415.60
7.0.120.0020.01517.82
7.0.110.0050.01617.75
7.0.100.0060.01417.61
7.0.90.0060.03117.82
7.0.80.0030.02117.74
7.0.70.0010.02117.76
7.0.60.0060.02117.70
7.0.50.0040.02017.89
7.0.40.0030.03515.79
7.0.30.0050.02015.77
7.0.20.0040.03015.82
7.0.10.0050.02215.87
7.0.00.0070.01415.70
5.6.400.0070.00714.36
5.6.390.0030.01114.26
5.6.380.0050.00814.52
5.6.370.0020.01214.48
5.6.360.0100.00314.34
5.6.350.0030.01014.28
5.6.340.0040.00514.36
5.6.330.0050.00814.50
5.6.320.0060.00714.38
5.6.310.0020.00914.63
5.6.300.0050.00814.73
5.6.290.0080.00614.24
5.6.280.0040.03016.58
5.6.270.0020.01716.61
5.6.260.0050.01416.76
5.6.250.0070.02616.73
5.6.240.0020.02416.52
5.6.230.0080.02016.56
5.6.220.0070.03016.63
5.6.210.0040.01616.61
5.6.200.0020.02116.77
5.6.190.0040.02516.65
5.6.180.0050.01816.64
5.6.170.0060.01716.62
5.6.160.0050.02016.40
5.6.150.0030.03616.62
5.6.140.0040.02516.54
5.6.130.0020.02116.70
5.6.120.0040.03416.63
5.6.110.0010.03816.54
5.6.100.0040.02216.70
5.6.90.0010.02516.55
5.6.80.0070.02816.29
5.6.70.0040.03216.34
5.6.60.0030.03116.30
5.6.50.0030.02816.44
5.6.40.0050.03116.29
5.6.30.0050.01616.39
5.6.20.0050.02016.40
5.6.10.0010.01916.43
5.6.00.0050.01816.20
5.5.380.0030.02515.43
5.5.370.0040.02015.31
5.5.360.0080.03115.39
5.5.350.0040.03115.49
5.5.340.0080.02115.63
5.5.330.0050.03015.56
5.5.320.0050.03215.87
5.5.310.0060.03415.68
5.5.300.0030.03315.75
5.5.290.0030.01915.48
5.5.280.0050.03215.71
5.5.270.0060.03015.60
5.5.260.0070.03115.70
5.5.250.0080.01915.53
5.5.240.0050.02315.36
5.5.230.0060.02815.24
5.5.220.0040.01715.42
5.5.210.0070.02715.30
5.5.200.0060.01615.26
5.5.190.0020.01815.38
5.5.180.0040.02315.34
5.5.170.0060.00714.23
5.5.160.0060.03115.45
5.5.150.0040.01915.34
5.5.140.0010.03515.29
5.5.130.0070.03115.27
5.5.120.0050.01815.36
5.5.110.0030.02115.33
5.5.100.0010.02315.25
5.5.90.0040.02115.40
5.5.80.0030.01915.35
5.5.70.0080.01315.36
5.5.60.0040.03115.33
5.5.50.0020.02515.34
5.5.40.0040.01715.18
5.5.30.0030.02715.18
5.5.20.0080.03015.33
5.5.10.0090.02715.49
5.5.00.0020.02515.16
5.4.450.0040.01613.98
5.4.440.0050.03114.00
5.4.430.0040.02814.03
5.4.420.0040.01713.95
5.4.410.0030.01613.91
5.4.400.0040.02613.91
5.4.390.0040.02913.82
5.4.380.0050.03013.86
5.4.370.0030.01713.85
5.4.360.0050.02613.82
5.4.350.0030.01613.90
5.4.340.0040.02713.88
5.4.330.0060.00211.35
5.4.320.0020.02513.92
5.4.310.0040.01413.87
5.4.300.0030.02013.90
5.4.290.0040.02413.82
5.4.280.0070.01213.87
5.4.270.0020.01813.86
5.4.260.0040.01713.88
5.4.250.0030.02013.87
5.4.240.0030.02913.99
5.4.230.0060.01313.84
5.4.220.0050.02413.92
5.4.210.0030.01613.82
5.4.200.0060.02613.88
5.4.190.0080.02913.91
5.4.180.0040.02913.87
5.4.170.0040.01913.82
5.4.160.0070.01513.89
5.4.150.0050.02213.88
5.4.140.0020.01613.03
5.4.130.0030.02712.91
5.4.120.0030.01913.05
5.4.110.0020.01913.15
5.4.100.0010.01712.93
5.4.90.0030.02212.99
5.4.80.0020.02212.96
5.4.70.0050.02913.05
5.4.60.0050.01313.06
5.4.50.0010.01613.06
5.4.40.0040.02113.02
5.4.30.0050.01513.01
5.4.20.0040.01312.99
5.4.10.0030.02113.02
5.4.00.0010.01712.74
5.3.290.0020.01812.41
5.3.280.0070.02412.38
5.3.270.0040.02412.31
5.3.260.0060.02912.32
5.3.250.0020.02612.36
5.3.240.0040.02112.36
5.3.230.0040.02012.34
5.3.220.0040.01512.35
5.3.210.0030.02112.29
5.3.200.0020.01712.32
5.3.190.0030.01612.31
5.3.180.0030.01612.30
5.3.170.0030.02412.30
5.3.160.0030.01512.37
5.3.150.0010.01912.30
5.3.140.0040.01412.29
5.3.130.0030.01512.35
5.3.120.0030.02312.28
5.3.110.0020.01812.37
5.3.100.0040.01412.13
5.3.90.0010.02512.14
5.3.80.0030.01612.11
5.3.70.0020.01712.14
5.3.60.0020.01412.13
5.3.50.0030.01612.16
5.3.40.0030.01612.12
5.3.30.0040.01912.11
5.3.20.0050.01212.04
5.3.10.0020.01812.07
5.3.00.0040.02212.02
5.2.170.0000.03311.04
5.2.160.0070.02311.21
5.2.150.0000.04011.12
5.2.140.0070.03311.16
5.2.130.0000.03311.17
5.2.120.0000.05311.03
5.2.110.0070.02011.02
5.2.100.0030.02711.04
5.2.90.0000.02711.02
5.2.80.0000.03711.02
5.2.70.0030.03711.04
5.2.60.0030.05011.00
5.2.50.0000.05010.94
5.2.40.0030.05710.94
5.2.30.0000.04010.89
5.2.20.0030.04010.84
5.2.10.0070.03010.86
5.2.00.0000.03310.72
5.1.60.0070.02010.07
5.1.50.0070.0239.94
5.1.40.0070.02310.03
5.1.30.0000.05710.41
5.1.20.0000.02710.32
5.1.10.0000.02310.05
5.1.00.0000.03010.14
5.0.50.0030.0279.94
5.0.40.0000.0479.94
5.0.30.0100.0209.94
5.0.20.0000.0209.94
5.0.10.0000.0239.94
5.0.00.0030.0479.94
4.4.90.0000.0239.94
4.4.80.0000.0339.94
4.4.70.0000.0309.94
4.4.60.0000.0139.94
4.4.50.0000.0179.94
4.4.40.0000.0209.94
4.4.30.0000.0239.94
4.4.20.0030.0139.94
4.4.10.0030.0309.94
4.4.00.0000.0239.94
4.3.110.0000.0239.94
4.3.100.0030.0179.94
4.3.90.0000.0209.94
4.3.80.0000.0309.94
4.3.70.0000.0279.94
4.3.60.0000.0179.94
4.3.50.0030.0209.94
4.3.40.0000.0239.94
4.3.30.0000.0179.94
4.3.20.0000.0239.94
4.3.10.0000.0139.94
4.3.00.0000.0179.94

preferences:
36.15 ms | 401 KiB | 5 Q