(no title)
LarryMade2 | 19 days ago
A thing for storing and comparing schedules
a weekly schedule is turned into a run-length list (the week is in minutes 0 to 10079 - so 540,1020,1980,2460 would be 9am to 5pm on Sunday and Monday). Makes it easy to unpack the list into an array and do basic math comparison can determine whether schedule A is within schedule B or get the difference in minutes that schedule A falls outside of schedule B etc.
I would say the most complicated ones I've done are some SQL queries where I had to break it into stages to reduce the amount of grinding it did on a query that was combining many tables.
No comments yet.