3v4l.org

run code in 300+ PHP versions simultaneously
<?php $interval_in_seconds = $settings['interval'] * 86400; $checkin_in_seconds = floor($checkin['timestamp'] / 1000); $next_checkin = $checkin_in_seconds + $interval_in_seconds; $until_next = $next_checkin - time(); if($until_next > 0) { $days = floor($until_next / 86400); function secondsToTime($seconds) { // Only here for var_dump testing: global $settings, $interval_in_seconds, $until_next, $next_checkin; $dtF = new DateTime("@0"); $dtT = new DateTime("@$seconds"); var_dump($until_next); $return = $dtF->diff($dtT)->format('%h hours, %i minutes and %s seconds'); var_dump($until_next); return $return; } $countdown = $days . ' days, ' . secondsToTime($until_next); } echo $countdown;

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.00.0040.01114.54
7.3.120.0100.00714.69
7.3.110.0030.01414.96
7.3.100.0060.00914.60
7.3.90.0060.00615.00
7.3.80.0130.00714.65
7.3.70.0060.00614.86
7.3.60.0120.00314.84
7.3.50.0030.00714.99
7.3.40.0130.00314.88
7.3.30.0000.01314.71
7.3.20.0030.01016.41
7.3.10.0090.00416.79
7.3.00.0090.00716.78
7.2.250.0030.01515.13
7.2.240.0030.01614.85
7.2.230.0030.01314.94
7.2.220.0060.00914.90
7.2.210.0100.01015.29
7.2.200.0030.01015.11
7.2.190.0090.00315.21
7.2.180.0070.00714.68
7.2.170.0040.01115.07
7.2.130.0090.00316.77
7.2.120.0040.01116.82
7.2.110.0030.00916.91
7.2.100.0000.01416.93
7.2.90.0090.00617.01
7.2.80.0110.00016.71
7.2.70.0070.00716.43
7.2.60.0120.00616.97
7.2.50.0000.00916.55
7.2.40.0000.01516.64
7.2.30.0040.00816.66
7.2.20.0100.00316.88
7.2.10.0030.00716.75
7.2.00.0060.00717.96
7.1.330.0060.01015.89
7.1.320.0060.00615.79
7.1.310.0040.01116.07
7.1.300.0040.00815.82
7.1.290.0100.00715.88
7.1.280.0070.00315.90
7.1.270.0000.01415.85
7.1.260.0000.01715.62
7.1.250.0030.00515.82
7.1.100.0040.00817.87
7.1.70.0000.00716.96
7.1.60.0090.00919.32
7.1.50.0030.01716.78
7.1.00.0070.07022.36
7.0.200.0000.00916.70
7.0.140.0130.06321.95
7.0.90.0170.06020.16
7.0.80.0070.05019.85
7.0.70.0070.04320.00
7.0.60.0230.06019.86
7.0.50.0100.08320.24
7.0.40.0030.07720.02
7.0.30.0170.07720.11
7.0.20.0030.07020.03
7.0.10.0130.07020.10
7.0.00.0030.04719.95
5.6.280.0030.07020.87
5.6.240.0000.04720.70
5.6.230.0130.06020.72
5.6.220.0030.07720.68
5.6.210.0000.07720.63
5.6.200.0030.05321.05
5.6.190.0070.05320.94
5.6.180.0030.08321.11
5.6.170.0170.07721.00
5.6.160.0130.07720.96
5.6.150.0030.08320.93
5.6.140.0070.08721.00
5.6.130.0200.06721.10
5.6.120.0030.08721.08
5.6.110.0130.05021.04
5.6.100.0000.08720.94
5.6.90.0170.08021.05
5.6.80.0100.05020.37
5.6.70.0070.04320.43
5.6.60.0070.08020.48
5.6.50.0030.03720.46
5.6.40.0070.03320.50
5.6.30.0000.05020.50
5.6.20.0030.03320.38
5.6.10.0070.07020.46
5.6.00.0070.07720.48
5.5.380.0030.08720.40
5.5.370.0070.04320.40
5.5.360.0070.06320.44
5.5.350.0170.03020.46
5.5.340.0100.08320.80
5.5.330.0070.07720.92
5.5.320.0100.08020.65
5.5.310.0130.08020.84
5.5.300.0130.06720.93
5.5.290.0030.05020.89
5.5.280.0100.08020.87
5.5.270.0070.08020.73
5.5.260.0000.08320.80
5.5.250.0000.08720.73
5.5.240.0100.06320.31
5.5.230.0130.07020.21
5.5.220.0200.03020.17
5.5.210.0070.04320.30
5.5.200.0100.06320.25
5.5.190.0130.06720.25
5.5.180.0030.08320.18
5.5.160.0070.03020.22
5.5.150.0000.08020.24
5.5.140.0000.04720.28
5.5.130.0130.06720.21
5.5.120.0030.08020.11
5.5.110.0070.06020.14
5.5.100.0100.06319.99
5.5.90.0170.06720.04
5.5.80.0100.06720.15
5.5.70.0030.05720.06
5.5.60.0030.08019.97
5.5.50.0070.05720.06
5.5.40.0100.08720.04
5.5.30.0130.07019.95
5.5.20.0030.08320.15
5.5.10.0070.08719.98
5.5.00.0100.07320.10
5.4.450.0000.05019.20
5.4.440.0070.06719.48
5.4.430.0030.05319.41
5.4.420.0030.04019.50
5.4.410.0030.08019.38
5.4.400.0130.06719.07
5.4.390.0100.05019.03
5.4.380.0070.07318.95
5.4.370.0030.07019.04
5.4.360.0030.03319.18
5.4.350.0030.07018.88
5.4.340.0070.06718.90
5.4.320.0070.07018.95
5.4.310.0000.06719.18
5.4.300.0070.07319.12
5.4.290.0100.07719.04
5.4.280.0070.04319.12
5.4.270.0070.04318.85
5.4.260.0070.03718.89
5.4.250.0030.06319.17
5.4.240.0130.07019.12
5.4.230.0070.06019.19
5.4.220.0070.08719.06
5.4.210.0000.07019.12
5.4.200.0330.03019.13
5.4.190.0030.06719.09
5.4.180.0170.07018.87
5.4.170.0000.07019.22
5.4.160.0100.03319.02
5.4.150.0170.06019.02
5.4.140.0030.07016.46
5.4.130.0070.07316.42
5.4.120.0070.07016.46
5.4.110.0030.04016.35
5.4.100.0070.04316.43
5.4.90.0070.07016.39
5.4.80.0100.03716.25
5.4.70.0070.05016.33
5.4.60.0070.07316.37
5.4.50.0100.05016.41
5.4.40.0130.06716.53
5.4.30.0030.07016.40
5.4.20.0100.02316.39
5.4.10.0100.07016.44
5.4.00.0100.06315.79
5.3.290.0000.05014.73
5.3.280.0100.07014.70
5.3.270.0130.06714.61
5.3.260.0030.04314.59
5.3.250.0030.04014.64
5.3.240.0000.08314.64
5.3.230.0100.05314.54
5.3.220.0030.04314.69
5.3.210.0000.08314.57
5.3.200.0070.07314.63
5.3.190.0000.04314.59
5.3.180.0130.06714.54
5.3.170.0070.05314.63
5.3.160.0030.06014.49
5.3.150.0000.08014.54
5.3.140.0030.07714.56
5.3.130.0000.08014.55
5.3.120.0000.07714.53
5.3.110.0030.06014.60
5.3.100.0000.03314.10
5.3.90.0030.08014.07
5.3.80.0000.06714.04
5.3.70.0070.07314.08
5.3.60.0100.06013.89
5.3.50.0100.06014.09
5.3.40.0070.07313.88
5.3.30.0030.06313.89
5.3.20.0030.04013.63
5.3.10.0070.03313.68
5.3.00.0070.03713.78
5.2.170.0030.03311.07
5.2.160.0030.06311.20
5.2.150.0030.03011.13
5.2.140.0030.03711.28
5.2.130.0030.03311.24
5.2.120.0030.05310.96
5.2.110.0100.04311.00
5.2.100.0000.05010.98
5.2.90.0070.03311.22
5.2.80.0070.02711.21
5.2.70.0000.04311.18
5.2.60.0000.03311.14
5.2.50.0030.03710.91
5.2.40.0030.02710.85
5.2.30.0070.02311.02
5.2.20.0000.03011.07
5.2.10.0030.02710.91
5.2.00.0030.02310.57
5.1.60.0030.02010.18
5.1.50.0030.02310.18
5.1.40.0000.02710.18
5.1.30.0000.02710.20
5.1.20.0000.02710.38
5.1.10.0030.02010.18
5.1.00.0000.02310.18
5.0.50.0000.01710.18
5.0.40.0000.02310.18
5.0.30.0000.03010.18
5.0.20.0000.01710.18
5.0.10.0070.01310.18
5.0.00.0030.02710.18
4.4.90.0000.02310.18
4.4.80.0030.01310.18
4.4.70.0000.01710.18
4.4.60.0000.01710.18
4.4.50.0000.01310.18
4.4.40.0000.02010.18
4.4.30.0030.01310.18
4.4.20.0000.01310.18
4.4.10.0070.01010.18
4.4.00.0000.02710.18
4.3.110.0030.02310.18
4.3.100.0000.01310.18
4.3.90.0030.01310.18
4.3.80.0030.02010.18
4.3.70.0000.02310.18
4.3.60.0000.03310.18
4.3.50.0000.01710.18
4.3.40.0030.01710.18
4.3.30.0030.01310.18
4.3.20.0030.01310.18
4.3.10.0030.01310.18
4.3.00.0000.01310.18

preferences:
35.45 ms | 401 KiB | 5 Q