r/badcode • • Dec 01 '19

[deleted by user]

[removed]

131 Upvotes

45 comments sorted by

View all comments

Show parent comment

3

u/[deleted] Dec 01 '19

Similar to mine, but using the date instead of the time to check for 24 hours. Technically wrong when leap seconds are involved, but mostly works.

2

u/[deleted] Dec 01 '19

My dude, it won't work properly unless you start the program exactly at 12am

2

u/[deleted] Dec 02 '19

And it still won't even if that happens, btw