by kccqzy · 2y ago · 0 comments
Technologists thought, how easy it is. A year has only a few hundred days, and there are only a few dozen possible rules for buses. Brute force is enough.
Nobody got the problem right. It gave me a great appreciation for how complex when technology interacts with culture and customs, long before my professional career.
Like I mentioned in a diff. comment, we generate all the official calendars of the org from this data. We print them, we generate .ics, etc.
So when a mistake happens, every employee that cares about that date will find someone to complain about it to, and ultimately someone somewhere goes, oh bother, we forgot to update the Calendar, and they promptly fix it.
Plus we avoid all blame, as it's very clear that we don't invent the calendar data. For us the HR dept is in charge of maintaining the calendar.
You’re still going to need that data entry guy. (Plus the two more that is the root problem)
if this data entry was so important, why is there only one guy responsible for it? where's the backup? where's the redundancy?
Sometimes, ad hoc things happen in our culture. Spurious bank holidays get added on a day’s notice in exceptional situations. These can be inserted into the cached DB. There is no calculation to back them.
Unexpected bank holidays (happened to me in 2002 during a financial crisis), official days of mourning, etc. Nothing to compute there: a government declares a holiday and you just enter it into the table.
Sure, you can compute Easter (you can just look up Knuth’s explanation of the algorithm for this…), but you can’t compute government decrees.
We do generate all the official calendars though, so we have print options to print various views of it(paydays, etc) and we also provide .ics feeds for Google/Apple Calendar, etc.
February 28, 1923 (Wednesday)
The nation of Greece used the Julian calendar for the last time before adopting the Gregorian calendar, used by most of the world, the next day. In that the Julian calendar was 13 days behind the Gregorian, the day was noted as "February 15". The next day was March 1 rather than February 16.
Ah, but that's not so. For example, if New Year's Day falls on a Saturday, then the NYSE doesn't observe the following Monday as a holiday - happened in 2022, for example.
They also avoid being closed more than 3 consecutive days, which is why they are open for trading on Black Friday (but they do close early!).
When you guys quote salaries in monthly figures.. Is the hourly rate fluctuating month to month based on the number of weekends and holidays? Or it vis a vis some standard amount of work days?
Yearly wage / yearly hours works
Th +10sih comes if you work more than weekly hours, or if you have a day-based contract (i.e. you don't count hours).
Most day-based contracts are written saying "you owe x days to the company in a given year", so a holiday on a weekend becomes irrelevant.
> Nobody got the problem right. It gave me a great appreciation for how complex when technology interacts with culture and customs, long before my professional career.
For those of us who weren't there, could you let us share in that appreciation: why wasn't brute force enough?
Seems like that is a red herring since Easter is always on a Sunday, which, it seems to me, is all that could possibly matter given the description of the problem.
edit: or, because the buses would observe the Easter holiday the next day, quoting OP:
> including the observed holiday which is the weekday after the holiday if the original holiday falls on a weekend.
Then you have Ash wednesday and some other holidays around Lent (6 weeks before Easter)…