I was set a challenge recently, in which the business requirements kept getting more complex. I rose to the challenge, but the final solution was made more complex by the fact that the requirements were iterative as opposed to being defined upfront.
The requirements evolved such:
- Can you find the difference, in hours, between two times in Excel
- Oh, can you exclude weekends
- Oh, and on the weekdays, can you exclude the times that are out of hours (i.e. before 9am, after 5pm doesn't count)
Here's the solution. It works, but because of the way it evolved, I no longer know how it works. So if you have any problems with it, don't come running to me!
