3v4l.org

run code in 300+ PHP versions simultaneously
<?php $now = new DateTime(); $midnight = clone $now; $midnight ->add(new DateInterval('P1D')) ->setTime(0, 0, 0) ; $difference = $midnight->diff($now); var_dump($difference->format('%H:%i:%s'));

preferences:
44.16 ms | 402 KiB | 5 Q