3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $curtime = date('Hi'); var_dump($curtime); $trading_hour['AT_open'] = '1715'; $trading_hour['AT_close'] = '0100'; if ($curtime <= '0100' || ($curtime >= '0830' && $curtime <= '2359')) { if ($curtime >= $trading_hour['AT_open'] || $curtime <= $trading_hour['AT_close']) { echo 'AT'; } else { echo 'N'; } }
based on A1Qv4
Output for 5.6.0 - 5.6.30, hhvm-3.15.4, 7.0.0 - 7.2.0
string(4) "0857" N