Computer time
From Teknologisk videncenter
Challenges
If you were tasked to write a program that would beep 100 minutes into the future based on local date and time clock. Sounds simple enough, but take these examples into consideration:
- Program starts 7 minutes before new year
- or 3 minutes before changing to summer time adding one hour to local time. Would your program beep after 40 or 100 minutes?
- or 70 minutes before changing back from summertime to normal time removing one hour.
- or how about 23:58 February 28th before a leap year or if a leap second was introduced.