3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = [ ['01/01/2016' , '05/05/2016'], ['01/07/2017' , '31/07/2017'], ['01/07/2017' , '01/08/2017'], ['01/07/2017' , '02/08/2017'] ]; foreach ($array as $row) { $start = DateTime::createFromFormat('d/m/Y' , $row[0]); $end = DateTime::createFromFormat('d/m/Y' , $row[1]); $diff = $start->diff($end); printf( "De %s até %s há %d dias.\n", $row[0], $row[1], ($diff->format('%m') * 30) + $diff->format('%d') ); }

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.70.0040.01118.31
8.3.60.0130.00616.63
8.3.50.0070.00918.15
8.3.40.0080.00818.95
8.3.30.0090.01218.96
8.3.20.0000.00720.25
8.3.10.0040.00422.09
8.3.00.0040.00423.65
8.2.190.0040.01416.58
8.2.180.0180.00418.25
8.2.170.0110.00422.96
8.2.160.0100.00320.53
8.2.150.0040.00424.18
8.2.140.0080.00024.66
8.2.130.0040.00422.27
8.2.120.0070.00026.35
8.2.110.0060.00322.18
8.2.100.0090.00317.97
8.2.90.0040.00418.16
8.2.80.0030.00517.97
8.2.70.0040.00418.05
8.2.60.0050.00318.34
8.2.50.0060.00318.10
8.2.40.0000.00819.43
8.2.30.0040.00419.48
8.2.20.0070.00018.20
8.2.10.0000.00818.32
8.2.00.0000.00718.21
8.1.280.0140.00325.92
8.1.270.0040.00420.48
8.1.260.0040.00426.35
8.1.250.0080.00028.09
8.1.240.0040.00423.92
8.1.230.0080.00320.89
8.1.220.0040.00417.79
8.1.210.0030.00518.79
8.1.200.0070.00317.48
8.1.190.0050.00317.35
8.1.180.0050.00318.10
8.1.170.0030.00718.77
8.1.160.0070.00019.09
8.1.150.0000.00718.98
8.1.140.0000.00717.66
8.1.130.0000.00719.10
8.1.120.0050.00217.63
8.1.110.0020.00517.48
8.1.100.0000.00817.59
8.1.90.0040.00417.53
8.1.80.0000.00817.52
8.1.70.0000.00717.54
8.1.60.0040.00417.49
8.1.50.0030.00517.59
8.1.40.0000.00817.64
8.1.30.0050.00317.69
8.1.20.0040.00417.63
8.1.10.0060.00317.61
8.1.00.0030.00717.57
8.0.300.0050.00320.09
8.0.290.0080.00017.00
8.0.280.0000.00718.48
8.0.270.0070.00017.40
8.0.260.0030.00318.66
8.0.250.0080.00417.25
8.0.240.0050.00217.23
8.0.230.0050.00317.12
8.0.220.0050.00317.05
8.0.210.0040.00417.08
8.0.200.0000.00817.17
8.0.190.0030.00617.28
8.0.180.0050.00217.18
8.0.170.0000.01017.21
8.0.160.0080.00017.06
8.0.150.0040.00417.18
8.0.140.0000.00717.07
8.0.130.0060.00013.61
8.0.120.0000.00717.20
8.0.110.0000.00816.97
8.0.100.0040.00417.21
8.0.90.0000.00716.98
8.0.80.0030.01217.25
8.0.70.0030.00517.04
8.0.60.0030.00417.17
8.0.50.0030.00617.19
8.0.30.0070.01317.27
8.0.20.0130.00817.43
8.0.10.0000.00717.32
8.0.00.0160.00317.01
7.4.330.0030.00315.55
7.4.320.0000.00616.62
7.4.300.0070.00016.61
7.4.290.0040.00416.45
7.4.280.0040.00416.67
7.4.270.0030.00316.61
7.4.260.0040.00416.70
7.4.250.0050.00316.40
7.4.240.0030.00316.63
7.4.230.0040.00416.71
7.4.220.0100.00716.65
7.4.210.0210.00016.57
7.4.200.0080.00016.80
7.4.160.0080.00816.57
7.4.150.0120.00817.40
7.4.140.0090.00817.86
7.4.130.0070.01416.63
7.4.120.0110.01016.75
7.4.110.0130.00516.73
7.4.100.0110.01216.45
7.4.90.0060.01516.70
7.4.80.0070.01119.39
7.4.70.0130.01016.61
7.4.60.0140.00716.81
7.4.50.0070.01016.45
7.4.40.0110.00616.75
7.4.30.0110.00716.81
7.4.00.0090.00514.94
7.3.330.0040.00413.32
7.3.320.0000.00513.35
7.3.310.0030.00316.47
7.3.300.0040.00416.49
7.3.290.0080.00716.41
7.3.280.0070.00916.36
7.3.270.0110.00617.40
7.3.260.0090.01016.56
7.3.250.0070.01016.67
7.3.240.0100.00916.50
7.3.230.0150.00316.59
7.3.210.0140.00316.47
7.3.200.0070.01016.67
7.3.190.0100.00716.55
7.3.180.0120.00616.41
7.3.170.0110.00716.61
7.3.160.0120.00616.76
7.3.120.0120.00614.99
7.3.110.0110.00714.98
7.3.100.0140.00315.13
7.3.90.0060.00615.16
7.3.80.0040.00715.01
7.3.70.0070.01014.76
7.3.60.0000.01015.24
7.3.50.0100.00314.82
7.3.40.0030.01414.67
7.3.30.0110.00414.89
7.3.20.0060.00916.82
7.3.10.0090.00716.58
7.3.00.0080.00616.65
7.2.330.0030.02016.70
7.2.320.0110.01116.93
7.2.310.0060.01116.93
7.2.300.0110.01116.74
7.2.290.0100.00716.68
7.2.250.0080.01114.84
7.2.240.0130.00315.39
7.2.230.0080.00415.14
7.2.220.0030.00615.23
7.2.210.0030.01015.30
7.2.200.0060.01015.40
7.2.190.0050.00515.05
7.2.180.0040.01115.09
7.2.170.0000.01115.27
7.2.130.0090.00816.62
7.2.120.0110.00716.66
7.2.110.0110.00616.85
7.2.100.0090.00816.85
7.2.90.0070.00916.87
7.2.80.0050.01316.67
7.2.70.0100.00516.83
7.2.60.0080.00816.82
7.2.50.0090.00516.88
7.2.40.0080.00817.00
7.2.30.0120.00616.96
7.2.20.0060.00816.72
7.2.10.0090.00516.73
7.2.00.0080.00717.03
7.1.330.0040.01116.05
7.1.320.0070.00316.04
7.1.310.0030.00915.79
7.1.300.0060.00615.71
7.1.290.0100.00315.58
7.1.280.0080.00015.84
7.1.270.0030.01015.82
7.1.260.0000.01316.04
7.1.250.0130.00515.86
7.1.200.0000.01416.11
7.1.100.3250.01016.18
7.1.90.3110.01016.03
7.1.80.2860.01016.21
7.1.70.6010.00615.50
7.1.60.4310.01033.56
7.1.50.4450.01433.19
7.1.40.3120.01032.70
7.1.30.4010.01032.63
7.1.20.3380.01332.98
7.1.10.4760.01615.21
7.1.00.3740.01315.11
7.0.240.3470.01316.08
7.0.230.3080.01315.66
7.0.220.3230.01015.52
7.0.210.3510.01014.70
7.0.200.5590.00615.13
7.0.190.4600.01014.92
7.0.180.4470.00314.71
7.0.170.5240.00614.46
7.0.160.5120.00714.55
7.0.150.2900.00714.48
7.0.140.4120.00614.32
7.0.130.3540.01614.84
7.0.120.3440.01314.88
7.0.110.4030.01414.38
7.0.100.3980.01014.51
7.0.90.3950.01014.56
7.0.80.3900.01314.88
7.0.70.4690.01314.64
7.0.60.2780.01014.57
7.0.50.3940.01014.49
7.0.40.2950.01014.65
7.0.30.1330.01314.64
7.0.20.3090.00614.65
7.0.10.1330.00714.73
7.0.00.5010.01014.57

preferences:
53.4 ms | 401 KiB | 5 Q