Hacker News new | ask | show | jobs
by gregwtmtno 1583 days ago
I never understood why programmers have such a hard time with time. There are two and only two pieces of information you need to work with time: seconds past the epoch and location. Everything else is applying legal and social context to the actual data.

Here both of those pieces of information are missing on all three questions, so no answers can be given. Any answer to these questions makes assumptions or deductions about those pieces of information.

4 comments

> Everything else is applying legal and social context to the actual data.

It's that "Everything else" that programmers have to deal with.

> Everything else is applying legal and social context to the actual data.

And then you just draw the rest of the owl.

I am with you but you missed a key issue of comparison: granularity.

Unix Epoch is by definition at granularity of seconds. How do you compare 2 epochs where one is in seconds while other in milliseconds. We sort of end up in same comparison game.

> There are two and only two pieces of information you need to work with time: seconds past the epoch and location. Everything else is applying legal and social context to the actual data.

Date-of-birth?

Calendar-quarters?

Computer-local time? (No location, only the computer's UTC offset).