3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class time { const second = 1000; const minute = 60000; const hour = 3600000; const day = 86400000; const week = 604800000; const month = 18144000000; static public function now() { return microtime(true); } static public function since ($time) { return microtime(true)-$time; } } $start = time::now(); sleep(2 * time::second); echo time::since($start);
based on tYG3C
Output for 5.3.15 - 7.2.6

Process exited with code 137.