News for hackers. Stuff that matters.
Re:30 years later, QBasic is still the best by TeMPOraL on Thursday May 05, 2016 @03:46PM (#11639155)
> My favorite is the date, where you months are 0 to 11, and days are 1 - 31.

I think this is something you need to blame UNIX for. Or who knows, maybe something made even earlier.

That said, there is a logic behind that. Days we usually represent with numbers. Months we often represent with names. So the month numbers are returned as an index of a sequence of names. (Not saying I like this logic, but it sort of makes sense.)

Re:30 years later, QBasic is still the best by eropple on Thursday May 05, 2016 @04:23PM (#11639393)
> I think this is something you need to blame UNIX for. Or who knows, maybe something made even earlier.

Continuing forward with bad designs doesn't absolve you from them, though. Plenty of languages avoid this--look at how .NET handles dates and times, it has no real relation to the underlying OS on either Windows or *nix.

Re:30 years later, QBasic is still the best by wvenable on Thursday May 05, 2016 @04:32PM (#11639451)
The fact that we typically represent dates as "05/05/2016" kind of ruins the argument that we don't represent months as numbers.
Re:30 years later, QBasic is still the best by kragen on Friday May 06, 2016 @06:20PM (#11647117)
This was a design error introduced by, apparently, Dennis Ritchie (RIP) in the early 1970s, when ctime() was split into asctime() and localtime(), around the time UNIX was rewritten in C. It kind of makes sense in the context of implementing ctime(). But it was still a design error.