Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

If all inputs are in hh:mm format, then there is no ambiguity of 930 as 9:30 am/pm. There could be a toggle for AM/PM.

Who puts seconds as an input for setting their morning alarm? MAD!



What's the unambiguous setting of 73:45 in hh:mm format?


3 days, 1 hour, 45 minutes. Simple.

The Android clock app silently corrects 73 minutes to 1 hour 13 minutes.

So for 1:13:45 (hh:mm:ss) you can input "7345" on the keypad and It. Just. Works.


But an alarm clock sets a relative point in time that happens every day. Putting "3 days" into a calendar is fine, but for an alarm clock it makes no sense.


So you add basic input validation.


Yes, but the person who originally proposed this argued that there was no ambiguity.


Invalid input, just as the empty string or a single digit would be.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: