SE will be down/read only today 2017-05-04 at 00:00 UTC until 00:20 UTC.
Your challenge is to output a truthy value if SE is down/read only and a falsy value if SE is not. You may not have any input, and you must use date builtins to determine if SE is down/read only (no actually querying the SE api!) Example output:
12:34 UTC 03 May 2017 -> false
00:00 UTC 04 May 2017 -> true
00:20 UTC 20 May 2017 -> undefined, see below
That's undefined behavior, because it's too far after the window of time.
To be clear, you can assume your program will be run from UTC 8:00
today (5/3/17) to UTC 1:00
tomorrow (5/4/17).
00:21 UTC 04 May 2017 -> false
00:20 UTC 04 May 2017 -> true
00:10 UTC 04 May 2017 -> true
Note that any truthy or falsy values are allowed, not just true
and false
. You must be accurate to the nearest second, and no changing the system clock! You may assume that your program is being run on a machine on the +0 UTC
time zone.
sudo time <insert time here> && echo true
\$\endgroup\$