5 ms·
... I understand the U.S. has a pretty woeful education system in some parts, but has it reached the point where converting 12 and 24h time is considered an adv
by waste_monk 5y ago
... I understand the U.S. has a pretty woeful education system in some parts, but has it reached the point where converting 12 and 24h time is considered an advanced task that is beyond the reach of most people? I'm morbidly curious.
- artogahr 5y agoThis is from just yesterday: https://news.ycombinator.com/item?id=30992322 https://news.ycombinator.com/item?id=30992322
- KSPAtlas 5y agoif time.ampm == PM: return time.hour + 12 else: return time.hour
- testmasterflex 5y agoYou’re right. Stupid question. Easy fix.
- Akronymus 5y ago12:24 pm?
- ericpp 5y agoif time.hour == 12 && time.ampm == AM: return 0 elif time.hour == 12 && time.ampm == PM: return 12 elif time.ampm == PM: return time.hour+12 else: return time.hour
- ericpp 5y agoThe vast majority of clocks in the US use 12 hour time. 24 hour time just isn't used here outside of limited applications (military, computing, etc). People generally aren't used to seeing time expressed in a 24 hour format. Most would choose a clock that shows the familiar 12 hour format over a 24 hour one that requires them to subtract 12 to get the time. I think it would be similar to selling a Fahrenheit thermometer in Europe. Most people could learn to do the conversion, but they would probably just buy a Celsius thermometer instead.