2 ms·
That... that way to handle leap years can't possibly be right, can it? It doesn't account that you don't need to add the leap day of the current year if the day
by zalyalov 3y ago
That... that way to handle leap years can't possibly be right, can it? It doesn't account that you don't need to add the leap day of the current year if the day is before Feb 29
- defrost 3y agoErr, my bad, I left out the prequel (still a one liner) y -= m < 3; dow = as above, etc; I was focused on an 'obscure' yet fundemental part of the C language pointer | array equivalence. Addendum: https://c-faq.com/misc/zeller.html https://c-faq.com/misc/zeller.html