3v4l.org

run code in 300+ PHP versions simultaneously
<?php $end_date = new DateTime(date("Y-m-d H:i:s", strtotime("14:00"))); $begin_date = new DateTime(date("Y-m-d H:i:s", strtotime("09:15"))); echo "begin_date is " . $begin_date->format('Y-m-d H:i:s') . " and end_date is " . $end_date->format('Y-m-d H:i:s') . "<br>"; $diff = ($end_date)->diff($begin_date); $diff_in_hours = $diff->h + $diff->i / 60; echo "The difference is " . $diff->h . " hours and " . $diff->i . " minutes, which is " . $diff_in_hours . " hours<br>";

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.0150.00618.42
8.3.50.0160.00522.11
8.3.40.0070.00718.88
8.3.30.0140.00019.22
8.3.20.0020.00520.16
8.3.10.0000.00823.70
8.3.00.0060.00319.38
8.2.180.0040.01116.50
8.2.170.0100.00722.96
8.2.160.0170.00320.38
8.2.150.0000.00824.18
8.2.140.0030.00524.66
8.2.130.0070.00026.16
8.2.120.0000.00819.66
8.2.110.0030.00621.04
8.2.100.0060.00617.75
8.2.90.0040.00419.21
8.2.80.0050.00317.97
8.2.70.0040.00817.50
8.2.60.0000.00817.93
8.2.50.0030.00618.07
8.2.40.0120.00018.28
8.2.30.0000.00718.20
8.2.20.0070.00017.82
8.2.10.0050.00318.04
8.2.00.0040.00417.86
8.1.280.0120.00925.92
8.1.270.0030.00620.70
8.1.260.0040.00426.35
8.1.250.0070.00028.09
8.1.240.0100.00019.25
8.1.230.0060.00619.08
8.1.220.0040.00417.74
8.1.210.0030.00618.77
8.1.200.0110.00317.38
8.1.190.0050.00317.48
8.1.180.0050.00318.10
8.1.170.0040.00418.70
8.1.160.0000.00722.02
8.1.150.0020.00518.90
8.1.140.0000.00717.64
8.1.130.0030.00517.90
8.1.120.0000.00717.66
8.1.110.0040.00417.56
8.1.100.0070.00017.64
8.1.90.0050.00217.55
8.1.80.0000.00717.59
8.1.70.0000.00817.61
8.1.60.0030.00517.77
8.1.50.0030.00617.66
8.1.40.0030.00617.54
8.1.30.0000.00817.68
8.1.20.0000.00817.74
8.1.10.0080.00017.73
8.1.00.0080.00017.53
8.0.300.0050.00318.77
8.0.290.0040.00416.88
8.0.280.0050.00318.53
8.0.270.0070.00017.39
8.0.260.0030.00317.35
8.0.250.0020.00517.07
8.0.240.0000.00717.16
8.0.230.0030.00317.07
8.0.220.0040.00417.02
8.0.210.0040.00417.14
8.0.200.0030.00317.20
8.0.190.0040.00417.14
8.0.180.0050.00217.16
8.0.170.0050.00316.98
8.0.160.0040.00417.04
8.0.150.0070.00016.94
8.0.140.0070.00017.05
8.0.130.0060.00013.52
8.0.120.0030.00517.08
8.0.110.0070.00017.11
8.0.100.0040.00417.17
8.0.90.0000.00716.96
8.0.80.0060.01317.12
8.0.70.0030.00516.96
8.0.60.0000.00716.98
8.0.50.0040.00417.08
8.0.30.0110.01017.33
8.0.20.0130.00917.42
8.0.10.0050.00217.14
8.0.00.0130.00617.09
7.4.330.0030.00315.17
7.4.320.0000.00716.60
7.4.300.0060.00016.55
7.4.290.0000.00816.78
7.4.280.0040.00416.55
7.4.270.0000.00716.69
7.4.260.0000.00816.68
7.4.250.0000.00716.55
7.4.240.0040.00416.62
7.4.230.0030.00316.71
7.4.220.0090.00916.65
7.4.210.0090.01116.51
7.4.200.0040.00416.75
7.4.160.0140.00816.63
7.4.150.0150.00017.40
7.4.140.0080.01317.86
7.4.130.0110.00816.59
7.4.120.0050.01316.71
7.4.110.0030.01416.59
7.4.100.0060.01216.65
7.4.90.0160.00816.57
7.4.80.0070.01119.39
7.4.70.0100.00716.76
7.4.60.0090.00916.50
7.4.50.0040.00416.46
7.4.40.0110.00716.74
7.4.30.0160.00016.82
7.4.10.0040.01414.93
7.4.00.0080.01014.92
7.3.330.0030.00313.30
7.3.320.0050.00013.16
7.3.310.0000.00716.28
7.3.300.0030.00316.45
7.3.290.0080.00516.44
7.3.280.0090.00916.42
7.3.270.0110.00617.40
7.3.260.0090.00916.63
7.3.250.0060.01216.46
7.3.240.0120.00616.58
7.3.230.0110.00616.63
7.3.210.0100.01016.68
7.3.200.0090.00619.39
7.3.190.0100.00816.51
7.3.180.0060.01216.60
7.3.170.0100.01016.71
7.3.160.0110.00416.54
7.3.130.0030.01414.96
7.3.120.0070.00715.05
7.3.110.0040.01614.88
7.3.100.0000.01414.89
7.3.90.0070.00714.68
7.3.80.0000.01515.01
7.3.70.0000.01414.77
7.3.60.0060.00914.77
7.3.50.0040.00814.89
7.3.40.0030.00915.02
7.3.30.0000.00914.93
7.3.20.0060.00816.81
7.3.10.0030.00616.55
7.3.00.0100.00616.91
7.2.330.0040.01516.53
7.2.320.0090.00916.96
7.2.310.0100.01316.80
7.2.300.0100.00717.10
7.2.290.0110.01216.79
7.2.260.0130.00614.98
7.2.250.0030.01414.92
7.2.240.0040.01115.19
7.2.230.0090.00615.40
7.2.220.0060.01015.31
7.2.210.0040.01415.45
7.2.200.0110.00315.31
7.2.190.0100.00715.31
7.2.180.0030.01415.28
7.2.170.0030.01015.09
7.2.160.0090.00615.09
7.2.150.0060.00317.21
7.2.140.0000.01016.84
7.2.130.0090.00617.08
7.2.120.0060.00617.08
7.2.110.0000.01016.82
7.2.100.0000.01417.08
7.2.90.0000.01316.86
7.2.80.0000.01216.93
7.2.70.0040.00817.05
7.2.60.0040.01016.96
7.2.50.0040.01117.13
7.2.40.0060.00616.94
7.2.30.0030.01216.75
7.2.20.0110.00417.17
7.2.10.0100.00616.98
7.2.00.0020.00918.32
7.1.330.0100.00316.12
7.1.320.0120.00315.89
7.1.310.0090.00615.77
7.1.300.0000.01015.96
7.1.290.0080.00315.87
7.1.280.0000.01415.88
7.1.270.0070.00715.63
7.1.260.0050.00316.02
7.1.250.0060.00615.75
7.1.240.0000.01116.03
7.1.230.0070.00715.75
7.1.220.0080.00616.00
7.1.210.0080.00616.04
7.1.200.0050.00515.82
7.1.190.0030.00915.95
7.1.180.0030.01315.63
7.1.170.0060.00315.97
7.1.160.0040.00815.71
7.1.150.0110.00415.98
7.1.140.0090.00615.96
7.1.130.0030.00915.66
7.1.120.0070.00716.02
7.1.110.0000.01116.05
7.1.100.0030.01116.91
7.1.90.0100.00316.04
7.1.80.0000.01315.94
7.1.70.0070.00516.57
7.1.60.0050.01417.58
7.1.50.0070.01116.54
7.1.40.0000.01315.88
7.1.30.0080.00515.95
7.1.20.0030.01015.90
7.1.10.0060.00915.88
7.1.00.0010.04319.11
7.0.330.0040.01215.48
7.0.320.0070.00715.57
7.0.310.0030.00715.59
7.0.300.0050.00315.48
7.0.290.0030.01015.68
7.0.280.0080.00015.57
7.0.270.0050.00315.42
7.0.260.0000.01115.22
7.0.250.0050.00315.58
7.0.240.0070.00715.65
7.0.230.0060.00615.52
7.0.220.0110.00015.50
7.0.210.0090.00615.55
7.0.200.0030.00816.27
7.0.190.0060.00615.31
7.0.180.0030.01015.53
7.0.170.0030.00615.66
7.0.160.0070.00715.43
7.0.150.0000.01015.50
7.0.140.0030.04218.79
7.0.130.0080.00415.44
7.0.120.0000.01415.25
7.0.110.0110.00415.34
7.0.100.0060.00615.66
7.0.90.0070.02817.83
7.0.80.0070.02717.54
7.0.70.0090.04517.80
7.0.60.0040.02817.74
7.0.50.0030.02918.05
7.0.40.0050.03516.82
7.0.30.0090.04616.81
7.0.20.0070.04816.84
7.0.10.0020.04616.83
7.0.00.0050.04716.82
5.6.400.0060.00614.09
5.6.390.0100.00014.26
5.6.380.0000.01614.04
5.6.370.0060.00913.88
5.6.360.0000.01414.16
5.6.350.0090.00314.17
5.6.340.0000.01014.29
5.6.330.0040.00713.97
5.6.320.0000.00914.37
5.6.310.0040.00814.34
5.6.300.0060.00314.29
5.6.290.0070.00713.99
5.6.280.0050.03917.52
5.6.270.0000.01314.21
5.6.260.0120.00013.84
5.6.250.0060.00614.14
5.6.240.0050.04517.31
5.6.230.0070.04517.42
5.6.220.0060.04317.31
5.6.210.0070.04317.29
5.6.200.0070.04317.53
5.6.190.0050.04417.50
5.6.180.0020.04417.57
5.6.170.0060.04317.67
5.6.160.0100.04117.54
5.6.150.0100.04517.48
5.6.140.0090.03117.67
5.6.130.0110.04417.62
5.6.120.0050.04717.51
5.6.110.0080.04717.57
5.6.100.0020.04017.63
5.6.90.0030.03017.53
5.6.80.0060.03217.22
5.6.70.0090.02517.28
5.6.60.0050.04017.26
5.6.50.0140.03817.25
5.6.40.0120.02217.09
5.6.30.0080.02017.17
5.6.20.0030.03117.20
5.6.10.0030.04317.19
5.6.00.0100.04217.20
5.5.380.0070.04217.20
5.5.370.0040.02517.10
5.5.360.0060.04217.14
5.5.350.0070.02317.33
5.5.340.0060.02317.53
5.5.330.0040.02317.41
5.5.320.0040.04917.26
5.5.310.0100.03717.40
5.5.300.0090.02717.55
5.5.290.0100.04317.38
5.5.280.0110.02117.41
5.5.270.0060.04317.42
5.5.260.0050.04717.58
5.5.250.0020.03017.38
5.5.240.0070.04117.00
5.5.230.0070.04817.28
5.5.220.0060.04017.01
5.5.210.0060.04317.09
5.5.200.0080.03517.00
5.5.190.0080.03717.15
5.5.180.0030.04817.10
5.5.170.0070.00313.99
5.5.160.0050.04217.16
5.5.150.0070.04717.10
5.5.140.0060.02917.21
5.5.130.0080.03617.12
5.5.120.0030.03217.15
5.5.110.0040.03316.96
5.5.100.0050.02916.95
5.5.90.0030.03317.09
5.5.80.0070.03716.93
5.5.70.0070.02516.92
5.5.60.0020.04316.98
5.5.50.0050.04216.94
5.5.40.0050.02916.97
5.5.30.0100.03916.71
5.5.20.0100.02016.76
5.5.10.0070.04216.80
5.5.00.0030.04617.01
5.4.450.0090.03715.18
5.4.440.0110.03915.28
5.4.430.0020.04715.13
5.4.420.0110.03615.08
5.4.410.0080.03714.92
5.4.400.0030.04315.12
5.4.390.0030.04114.80
5.4.380.0050.04314.80
5.4.370.0050.02814.98
5.4.360.0070.04214.97
5.4.350.0100.03314.91
5.4.340.0050.02814.99
5.4.330.0030.00710.73
5.4.320.0080.04014.88
5.4.310.0050.03714.94
5.4.300.0060.02314.96
5.4.290.0070.04014.85
5.4.280.0060.04015.03
5.4.270.0050.02315.07
5.4.260.0070.01814.87
5.4.250.0070.03714.84
5.4.240.0050.02514.97
5.4.230.0050.03015.13
5.4.220.0030.03214.80
5.4.210.0020.02514.93
5.4.200.0050.04015.00
5.4.190.0000.03015.10
5.4.180.0100.03514.78
5.4.170.0050.02114.89
5.4.160.0030.04014.78
5.4.150.0070.02014.71
5.4.140.0020.04313.50
5.4.130.0040.04213.49
5.4.120.0080.03713.68
5.4.110.0090.03713.51
5.4.100.0090.03813.70
5.4.90.0050.04113.49
5.4.80.0090.02913.60
5.4.70.0020.03713.43
5.4.60.0020.04513.60
5.4.50.0040.04313.63
5.4.40.0080.03813.66
5.4.30.0050.02013.70
5.4.20.0030.03813.52
5.4.10.0030.02013.68
5.4.00.0020.02213.33
5.3.290.0130.07014.62
5.3.280.0030.04014.56
5.3.270.0070.04014.46
5.3.260.0070.07314.61
5.3.250.0070.07314.45
5.3.240.0070.04014.54
5.3.230.0030.05314.44
5.3.220.0100.07014.52
5.3.210.0100.05314.54
5.3.200.0100.03314.38
5.3.190.0030.07714.57
5.3.180.0030.07314.39
5.3.170.0070.07714.56
5.3.160.0030.05314.42
5.3.150.0070.07314.53
5.3.140.0070.07314.50
5.3.130.0030.04314.54
5.3.120.0100.06714.41
5.3.110.0030.07314.46
5.3.100.0000.04014.04
5.3.90.0030.03713.98
5.3.80.0030.03713.98
5.3.70.0130.03013.80
5.3.60.0070.03313.87
5.3.50.0000.04313.81
5.3.40.0100.03013.80
5.3.30.0000.04013.90
5.3.20.0030.03313.46
5.3.10.0070.02713.64
5.3.00.0100.03013.55
5.2.170.0030.03011.18
5.2.160.0000.04310.98
5.2.150.0000.03011.20
5.2.140.0030.03010.98
5.2.130.0000.03311.05
5.2.120.0030.02711.09
5.2.110.0000.03310.96
5.2.100.0030.03310.96
5.2.90.0030.02711.07
5.2.80.0030.02711.12
5.2.70.0000.03011.02
5.2.60.0030.03011.04
5.2.50.0100.02310.97
5.2.40.0000.03011.05
5.2.30.0030.02710.79
5.2.20.0070.02311.02
5.2.10.0030.02710.79
5.2.00.0000.03010.74
5.1.60.0000.02710.26
5.1.50.0000.02710.26
5.1.40.0000.02710.26
5.1.30.0000.03010.26
5.1.20.0000.03310.36
5.1.10.0000.02710.26
5.1.00.0000.02710.26
5.0.50.0070.01310.26
5.0.40.0030.01710.26
5.0.30.0030.02710.26
5.0.20.0000.02010.26
5.0.10.0030.01710.26
5.0.00.0030.03710.26
4.4.90.0000.01710.26
4.4.80.0000.02010.26
4.4.70.0000.02710.26
4.4.60.0000.01310.26
4.4.50.0100.02010.26
4.4.40.0000.02310.26
4.4.30.0030.01310.26
4.4.20.0000.02010.26
4.4.10.0000.01710.26
4.4.00.0000.02710.26
4.3.110.0000.01710.26
4.3.100.0000.01310.26
4.3.90.0000.01310.26
4.3.80.0000.02310.26
4.3.70.0030.01010.26
4.3.60.0000.01710.26
4.3.50.0000.02310.26
4.3.40.0000.02710.26
4.3.30.0000.03010.26
4.3.20.0000.02310.26
4.3.10.0000.01710.26
4.3.00.0000.03010.26

preferences:
44.99 ms | 401 KiB | 5 Q