3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $h = 72; $prog = new DateTime('2015-11-01 17:23'); $interval = $prog->diff(new DateTime()); $ih = $interval->d * 24 + $interval->h; $delay = $h - $ih; echo $delay;
based on 1Prfc
Output for 5.3.19 - 5.4.45, 5.6.28, 7.0.20 - 7.2.0
2
Output for 7.0.6
24
Output for 7.0.5
35
Output for 7.0.4
-145
Output for 7.0.3
-338
Output for 7.0.2
-440
Output for 7.0.1
-468
Output for 7.0.0
-541
Output for 5.6.21
52
Output for 5.6.20
-132
Output for 5.6.19
-81
Output for 5.6.18
-258
Output for 5.6.17
-365
Output for 5.6.16
-566
Output for 5.6.15
-591
Output for 5.6.14
55
Output for 5.6.13
-261
Output for 5.6.12
-372
Output for 5.6.11
-474
Output for 5.6.10
-500
Output for 5.6.9
-553
Output for 5.6.8
-610
Output for 5.5.35
-434
Output for 5.5.34
-158
Output for 5.5.33
-107
Output for 5.5.32
-309
Output for 5.5.31
-392
Output for 5.5.30
-665
Output for 5.5.29
-300
Output for 5.5.28
-399
Output for 5.5.27
-425
Output for 5.5.26
-527
Output for 5.5.25
-582
Output for 5.5.24
-478