Re:Day of Week Algorithm
by mrdrozdov on Friday March 25, 2016 @01:57PM
(#11361577)
Seems relevant, Cron supports using 0 or 7 to refer to Sunday.
[ Parent
| on HN ]
What a fascinating way to solve the problem.
You want Sunday as the first day? Fine, do your index zero-based and Sunday is Zero.
You want Monday as the first day? Fine, index 1-based and use 7 for Sunday.
Kind of brilliant.