Live data from Hacker News

Falsehoods programmers believe about time

infiniteundo.com

31–40 of 212 posts

Re: Falsehoods programmers believe about time

#31

"Months have either 28, 29, 30, or 31 days." Ok, Im intrigued, are there months that don't? I assume it must be a country specific thing?

Most countries had at least one month that differed some time from 1580ish to 1800ish when they switched calenders Don't know about more recent examples

https://en.wikipedia.org/wiki/List_of_adoption_dates_of_the_...

Actually looking at that tells me it is a mess... Like Belarus and Lithuania changing back to Julian calendar in 1800... And then again to Gregorian in 1918.

Re: Falsehoods programmers believe about time

#32
post #16
post #10

> There are always 24 hours in a day. Is this referring to leap seconds or what do the mean?

Daylight savings, or the device is on a plane and travels through timezones.

Or, back when I was doing airborne geophysical surveying across the Fijian archipelago the plane would flit from -179 to +179 longitude a few times every hour with a potential change of a full day if being naive about time zones.

Data aquisition instrumentation needs to use a lapsed epoch (to avoid UTC leap seconds) with a calibration at start and end of projects to adjust for drift, etc.

Re: Falsehoods programmers believe about time

#34
post #30

Earlier quoted context omitted.

If I am not wrong this holds true for the switch from Julian calendar to the Gregorian one. Some months were shortened to be synchronised with the new system. And if I am not mistaken Jewish and Arabs do not use the same systems we use for months and years

For an added twist this changeover occurred in different years, at different times in different countries .. and not always with the same number of days difference. Good Times.

And even more good times. It seems sometimes some countries went back to Julian...

Re: Falsehoods programmers believe about time

#37
post #21

Earlier quoted context omitted.

I'd expect in a lunar calendar system? (where 12 lunar months are to short to fill a year, and I think some of them fix this by inserting an extra half-month) But I wish this list came with examples, and if it really means a different calendar system it's IMHO not as interesting, because it's IMHO fairly obvious that different calendar systems follow different rules. Or maybe during the switch to Gregorian calendar?…

Lunar month is a little over 29 days on average. And most lunar calendars do not align with solar year but rather have leap months added. E.g. Hebrew calendar [1]. [1]: https://en.wikipedia.org/wiki/Hebrew_calendar

Ok, you made me look up an example: "The Ethiopian calendar has twelve months of thirty days plus five or six epagomenal days, which comprise a thirteenth month."

https://en.wikipedia.org/wiki/Intercalation_(timekeeping)

https://en.wikipedia.org/wiki/Ethiopian_calendar

I guess its the choice if you fix the offset every year or wait until you accumulate a full month of offset.

Re: Falsehoods programmers believe about time

#39

> A week (or a month) always begins and ends in the same year Okay, of course a week can begin in an year and end in the next, but how exactly would a month not begin and end in the same year?

Here you go: https://youtu.be/-5wpm-gesOY?t=368

I'd highly recommend watching the whole video, by the way. It's really good.

Re: Falsehoods programmers believe about time

#40
Also one thing I have noticed is that the system clocks are actually pretty bad. Or I would expect them to be much better. This can be easily noticed when you don't have active time sync on machine. Drift is multiple seconds in not that many days.
Post reply on HN