3v4l.org

run code in 300+ PHP versions simultaneously
<?php $date = "2014-11-29"; $today = date('Y-m-d'); echo $today; $diff = abs(strtotime($date) - strtotime($today)); $years = floor($diff / (365*60*60*24)); $months = floor(($diff - $years * 365*60*60*24) / (30*60*60*24)); $days = floor(($diff - $years * 365*60*60*24 - $months*30*60*60*24)/ (60*60*24)); echo $days;

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.0070.00716.58
8.3.60.0070.01116.50
8.3.50.0080.00722.02
8.3.40.0100.01018.88
8.3.30.0070.00719.22
8.3.20.0070.00020.21
8.3.10.0030.00520.59
8.3.00.0030.00519.63
8.2.180.0040.01218.38
8.2.170.0040.01422.96
8.2.160.0100.00720.35
8.2.150.0040.00424.18
8.2.140.0060.00324.66
8.2.130.0070.00726.16
8.2.120.0080.00019.48
8.2.110.0060.00322.23
8.2.100.0080.00417.97
8.2.90.0040.00419.17
8.2.80.0040.00417.97
8.2.70.0000.00917.75
8.2.60.0070.00318.03
8.2.50.0080.00018.07
8.2.40.0000.00718.28
8.2.30.0000.00719.37
8.2.20.0040.00417.85
8.2.10.0040.00418.30
8.2.00.0030.00617.86
8.1.280.0040.01125.92
8.1.270.0080.00024.10
8.1.260.0000.00726.35
8.1.250.0070.00028.09
8.1.240.0000.00823.97
8.1.230.0040.00818.99
8.1.220.0030.00517.91
8.1.210.0040.00418.77
8.1.200.0030.00617.60
8.1.190.0040.00417.38
8.1.180.0000.00918.10
8.1.170.0070.00318.68
8.1.160.0040.00422.00
8.1.150.0000.00718.94
8.1.140.0040.00417.62
8.1.130.0030.00317.96
8.1.120.0030.00517.66
8.1.110.0000.00717.68
8.1.100.0000.00817.64
8.1.90.0070.00017.69
8.1.80.0070.00017.64
8.1.70.0000.00817.46
8.1.60.0060.00317.60
8.1.50.0040.00417.54
8.1.40.0020.00517.54
8.1.30.0040.00417.76
8.1.20.0070.00017.80
8.1.10.0070.00017.69
8.1.00.0080.00017.74
8.0.300.0000.00718.77
8.0.290.0050.00217.00
8.0.280.0070.00018.59
8.0.270.0080.00017.33
8.0.260.0070.00017.45
8.0.250.0030.00317.23
8.0.240.0050.00317.20
8.0.230.0000.00717.09
8.0.220.0040.00417.21
8.0.210.0030.00417.17
8.0.200.0030.00517.29
8.0.190.0060.00317.02
8.0.180.0040.00417.20
8.0.170.0050.00317.02
8.0.160.0000.00717.16
8.0.150.0070.00016.95
8.0.140.0050.00316.94
8.0.130.0070.00013.48
8.0.120.0070.00016.95
8.0.110.0060.00317.08
8.0.100.0040.00416.98
8.0.90.0020.00517.14
8.0.80.0100.01116.98
8.0.70.0020.00517.11
8.0.60.0050.00217.06
8.0.50.0050.00316.94
8.0.30.0150.00717.20
8.0.20.0150.00717.40
8.0.10.0040.00417.06
8.0.00.0090.00916.85
7.4.330.0000.00515.09
7.4.320.0030.00616.72
7.4.300.0030.00316.57
7.4.290.0070.00016.59
7.4.280.0060.00016.61
7.4.270.0030.00316.64
7.4.260.0040.00416.62
7.4.250.0000.00716.69
7.4.240.0000.00716.63
7.4.230.0050.00216.84
7.4.220.0160.00616.51
7.4.210.0100.01016.73
7.4.200.0030.00316.64
7.4.160.0080.00816.84
7.4.150.0090.00917.40
7.4.140.0100.00817.86
7.4.130.0100.00716.79
7.4.120.0130.00916.73
7.4.110.0040.01416.89
7.4.100.0060.01116.73
7.4.90.0070.01016.59
7.4.80.0110.00619.39
7.4.70.0140.01016.69
7.4.60.0130.00316.63
7.4.50.0040.00416.79
7.4.40.0100.00716.71
7.4.30.0100.00616.64
7.4.00.0060.00914.88
7.3.330.0060.00013.39
7.3.320.0000.00513.43
7.3.310.0030.00316.56
7.3.300.0040.00416.54
7.3.290.0070.01116.61
7.3.280.0130.00416.49
7.3.270.0090.00917.40
7.3.260.0030.01316.55
7.3.250.0100.00916.58
7.3.240.0160.00616.63
7.3.230.0120.00416.59
7.3.210.0060.01216.64
7.3.200.0080.00819.39
7.3.190.0080.00816.70
7.3.180.0060.00916.73
7.3.170.0060.01016.61
7.3.160.0070.01016.74
7.3.00.0040.01116.50
7.2.330.0030.01416.97
7.2.320.0090.01516.77
7.2.310.0180.00316.74
7.2.300.0070.01016.70
7.2.290.0120.00416.80
7.2.130.0040.01117.07
7.2.120.0030.01316.77
7.2.110.0030.01016.91
7.2.100.0130.00417.01
7.2.90.0110.00416.81
7.2.80.0100.00616.61
7.2.70.0120.00616.93
7.2.60.0060.00916.86
7.2.50.0070.01317.06
7.2.40.0000.00916.85
7.2.30.0070.01016.96
7.2.20.0000.01417.05
7.2.10.0060.01016.78
7.2.00.0020.01218.17
7.1.250.0080.00315.75
7.1.240.0030.00916.12
7.1.230.0000.01115.80
7.1.220.0030.01015.93
7.1.210.0070.00715.87
7.1.200.0030.00916.00
7.1.190.0170.00016.05
7.1.180.0040.00715.48
7.1.170.0060.01015.82
7.1.160.0090.00915.72
7.1.150.0000.01415.96
7.1.140.0030.01016.01
7.1.130.0100.00315.56
7.1.120.0060.00315.83
7.1.110.0040.01015.67
7.1.100.0060.00717.06
7.1.90.0100.00615.82
7.1.80.0100.00615.88
7.1.70.0030.00616.63
7.1.60.0050.00817.64
7.1.50.0090.00816.64
7.1.40.0120.00016.09
7.1.30.0000.01615.84
7.1.20.0080.00315.96
7.1.10.0070.00715.64
7.1.00.0050.04119.15
7.0.330.0070.00715.39
7.0.320.0040.01115.59
7.0.310.0030.01315.43
7.0.300.0040.01115.72
7.0.290.0140.00015.35
7.0.280.0160.00015.11
7.0.270.0100.00715.45
7.0.260.0040.00815.46
7.0.250.0000.01315.52
7.0.240.0100.00515.43
7.0.230.0070.00415.58
7.0.220.0120.00315.61
7.0.210.0040.01115.38
7.0.200.0290.00415.39
7.0.190.0060.00515.48
7.0.180.0090.00515.60
7.0.170.0030.01015.48
7.0.160.0060.00615.66
7.0.150.0110.00015.57
7.0.140.0030.04218.83
7.0.130.0080.00415.23
7.0.120.0000.00915.70
7.0.110.0000.01515.30
7.0.100.0030.01015.60
7.0.90.0100.03217.76
7.0.80.0030.03917.78
7.0.70.0070.02717.84
7.0.60.0060.04017.76
7.0.50.0060.04318.04
7.0.40.0030.04716.82
7.0.30.0130.04116.90
7.0.20.0090.03916.82
7.0.10.0030.04916.94
7.0.00.0080.03716.87
5.6.380.0090.00514.38
5.6.370.0060.01214.62
5.6.360.0110.00314.27
5.6.350.0120.00014.32
5.6.340.0070.00714.36
5.6.330.0080.00814.39
5.6.320.0080.00614.50
5.6.310.0030.01014.63
5.6.300.0070.00714.35
5.6.290.0040.01114.59
5.6.280.0030.04217.93
5.6.270.0030.01014.33
5.6.260.0110.00014.40
5.6.250.0030.01314.64
5.6.240.0070.04217.48
5.6.230.0100.04117.38
5.6.220.0090.02517.56
5.6.210.0050.04117.48
5.6.200.0080.02817.70
5.6.190.0060.03017.63
5.6.180.0060.03017.60
5.6.170.0110.02817.76
5.6.160.0120.03117.77
5.6.150.0000.05017.72
5.6.140.0090.04317.73
5.6.130.0070.03817.69
5.6.120.0110.02217.76
5.6.110.0070.02817.79
5.6.100.0120.04317.78
5.6.90.0050.04017.69
5.6.80.0070.03817.25
5.6.70.0100.03317.31
5.6.60.0100.03617.36
5.6.50.0080.03017.41
5.6.40.0080.03317.42
5.6.30.0080.04217.32
5.6.20.0050.04717.51
5.6.10.0080.03017.39
5.6.00.0050.02617.42
5.5.380.0050.02715.78
5.5.370.0090.04115.77
5.5.360.0070.04015.74
5.5.350.0110.02015.80
5.5.340.0120.03815.97
5.5.330.0070.02716.08
5.5.320.0050.04415.97
5.5.310.0100.02315.90
5.5.300.0050.04716.03
5.5.290.0070.04216.04
5.5.280.0060.04315.98
5.5.270.0100.04316.02
5.5.260.0110.03015.95
5.5.250.0100.01815.93
5.5.240.0060.03115.77
5.5.230.0050.04515.69
5.5.220.0060.04315.70
5.5.210.0070.04015.71
5.5.200.0100.03815.66
5.5.190.0050.02515.69
5.5.180.0030.04315.72
5.5.170.0060.00611.18
5.5.160.0100.03215.70
5.5.150.0100.04015.69
5.5.140.0090.04015.65
5.5.130.0080.04015.65
5.5.120.0030.02715.71
5.5.110.0050.04315.67
5.5.100.0020.02715.63
5.5.90.0100.03715.74
5.5.80.0080.04115.61
5.5.70.0090.04215.57
5.5.60.0080.03615.64
5.5.50.0080.02615.62
5.5.40.0070.03815.63
5.5.30.0070.04015.61
5.5.20.0020.04715.64
5.5.10.0030.04415.64
5.5.00.0050.04015.61
5.4.450.0080.04115.24
5.4.440.0080.04215.24
5.4.430.0060.04015.32
5.4.420.0080.03315.23
5.4.410.0050.02315.20
5.4.400.0020.03215.16
5.4.390.0070.04015.16
5.4.380.0050.02815.16
5.4.370.0000.03215.04
5.4.360.0050.03314.99
5.4.350.0030.04015.24
5.4.340.0070.02815.15
5.4.330.0070.00711.18
5.4.320.0010.03515.15
5.4.310.0100.03815.11
5.4.300.0040.04415.10
5.4.290.0080.03315.10
5.4.280.0050.04015.06
5.4.270.0090.03715.14
5.4.260.0050.02615.16
5.4.250.0090.03615.13
5.4.240.0050.04215.12
5.4.230.0070.02715.11
5.4.220.0030.02115.14
5.4.210.0070.04314.99
5.4.200.0050.04515.05
5.4.190.0050.04315.07
5.4.180.0030.04015.07
5.4.170.0040.03715.09
5.4.160.0070.02015.12
5.4.150.0070.04015.02
5.4.140.0030.04313.83
5.4.130.0030.04013.77
5.4.120.0070.03713.80
5.4.110.0050.04213.82
5.4.100.0080.02313.83
5.4.90.0080.02513.77
5.4.80.0080.03713.73
5.4.70.0040.03213.77
5.4.60.0090.03913.69
5.4.50.0070.03013.71
5.4.40.0080.04213.77
5.4.30.0060.04013.78
5.4.20.0090.03713.70
5.4.10.0080.03713.74
5.4.00.0040.04213.49
5.3.290.0060.04412.92
5.3.280.0020.04312.81
5.3.270.0050.04212.88
5.3.260.0070.03112.88
5.3.250.0010.02612.87
5.3.240.0070.03812.88
5.3.230.0030.04412.87
5.3.220.0080.03712.84
5.3.210.0070.04312.86
5.3.200.0150.03312.85
5.3.190.0070.03912.80
5.3.180.0030.04212.87
5.3.170.0080.04012.80
5.3.160.0080.03812.86
5.3.150.0100.03812.84
5.3.140.0110.03112.86
5.3.130.0090.02512.84
5.3.120.0050.04512.86
5.3.110.0050.04012.87
5.3.100.0060.02912.61
5.3.90.0020.03812.57
5.3.80.0030.04012.51
5.3.70.0070.03912.48
5.3.60.0080.03512.59
5.3.50.0090.03512.56
5.3.40.0030.04112.49
5.3.30.0060.03912.43
5.3.20.0020.04412.36
5.3.10.0060.04212.34
5.3.00.0050.03712.39
5.2.170.0050.02211.16
5.2.160.0020.02311.07
5.2.150.0070.01511.05
5.2.140.0050.02311.18
5.2.130.0020.03011.15
5.2.120.0070.03811.16
5.2.110.0080.02811.11
5.2.100.0050.03511.10
5.2.90.0050.03211.16
5.2.80.0050.03311.13
5.2.70.0000.02611.13
5.2.60.0060.03311.13
5.2.50.0020.02411.05
5.2.40.0050.03311.01
5.2.30.0070.03211.10
5.2.20.0080.02811.03
5.2.10.0030.02511.02
5.2.00.0040.02110.97
5.1.60.0060.02510.74
5.1.50.0050.02310.74
5.1.40.0030.01810.74
5.1.30.0010.01810.81
5.1.20.0030.01910.83
5.1.10.0020.02810.74
5.1.00.0030.03210.74
5.0.50.0030.02410.74
5.0.40.0030.02510.74
5.0.30.0020.02710.74
5.0.20.0070.02310.74
5.0.10.0000.02410.74
5.0.00.0020.03510.74
4.4.90.0000.01210.74
4.4.80.0020.01910.74
4.4.70.0020.02010.74
4.4.60.0030.01810.74
4.4.50.0020.02010.74
4.4.40.0020.03010.74
4.4.30.0020.01110.74
4.4.20.0030.01810.74
4.4.10.0020.01710.74
4.4.00.0070.02510.74
4.3.110.0020.01210.74
4.3.100.0000.02110.74
4.3.90.0020.01710.74
4.3.80.0020.02010.74
4.3.70.0030.01310.74
4.3.60.0000.01810.74
4.3.50.0040.01310.74
4.3.40.0000.02810.74
4.3.30.0030.02110.74
4.3.20.0030.01010.74
4.3.10.0030.01010.74
4.3.00.0010.01610.74

preferences:
54.05 ms | 401 KiB | 5 Q