In the code I'm working on, I need to sort observations according to various criteria: weekday vs. weekend, inside network vs. outside network. etc. All of them worked, except the one where I sort according to whether the observation is during the workday, 9 to 5. Everything was marked as being outside the workday. But the code was crystal clear: if the observation is after the start hour and before the end hour, mark it as working hours.
I must have looked at the method call a dozen times, "isWorkingHour(time, 9, 5)" before it finally dawned on me that I had been returning the times for a 24-hour clock for a REASON.
Is it 5PM yet? I'm ready to go home.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment