I work a standard nine to five. Monday through Friday. I take a half hour for lunch from 12:30 to 13:00.
Write me a program which, when run, calculates the percentage of the working week that I have completed at the current moment.
- Only count time actually spent working. I am punctual and do not work over lunch.
- No input. You may obtain information like current time/date however is convenient.
- The working week is considered complete from end-of-day Friday to midnight between Sunday and Monday.
- Timezone is the local timezone.
- Output should be a decimal number, eg 66.25498, percentage symbol optional.
- The program should be reasonably future-proof. It should be able to cope with leap years.
- Output resolution should be a second or better. I like to watch the kettle boil.
- Code golf. Shortest code wins.