Talk:2867: DateTime

Explain xkcd: It's 'cause you're dumb.
Jump to: navigation, search

Comics like this are why this wiki exists. 172.70.100.172 23:30, 13 December 2023 (UTC)

The time falsehoods gist linked above is a really good explanation about why a programmer might panic about calculating time. Especially the ones about calling "getCurrentTime()" twice in a row doesn't always mean the results are in the order you think they were called, or even different values. t2 might very well be the same or less than t1. It can be maddening. 162.158.197.149 23:40, 13 December 2023 (UTC)
The last item is the most important to me: Users prefer to use the local timezone. This causes so much frustration while browsing the web! PissedOff.gif --162.158.110.68 00:26, 14 December 2023 (UTC)
Worth noting that events can take place over long periods. A sunspot or an illness or a relationship doesn't happen at a single point in time, it takes place over days or weeks or longer. When did it "start"? Who knows? Also I miss calling TI4-1212 here in DC. 172.70.175.27 01:39, 14 December 2023 (UTC)
Out of curiosity, could someone explain the item in that time falsehoods list that says "Months have either 28, 29, 30, or 31 days"? My guess is that it's a reference to their being more calendars in the world than Gregorian? But I'm not sure if there's more than that going on, there.ModelD (talk) 18:18, 14 December 2023 (UTC)
Isn't that true of Gregorian calendars? February has 28 or 29 depending on the year, AJSN have 30 and JMMJAOD have 31.Gavin (talk) 18:33, 14 December 2023 (UTC)
It's saying that "months have either 28, 29, 30, or 31 days" is a falsehood. The first one that comes to mind is the switch from the Julian calendar to the Gregorian calendar: "In North America, for example, the month of September 1752 had only 19 days, as the day count went straight from September 2 to September 14". 172.70.43.108 21:03, 14 December 2023 (UTC)
(Ninjaed, with an actual example! But retrying reply anyway as it had other details.) But how many days had <insert your choice of month(s) during which a given system changed from Julian to Gregorian>? I think possibly, without looking up when each and every transition occured, below 20 days is possible. (As in the nth of one month to the nth of the next is less than 20 days, for the right month and a number of ns. For other ns, you can only actually count from the month before to the month after (two full calendar months), the daycount for that being below the typical bimonthly stretch of 59, 60, 61 or 62 days (under more standard conditions)... 172.70.90.48 21:07, 14 December 2023 (UTC)
The shortest month might be February 1923 in Greece, which had only 15 days. The most recent such instance seems to be December 1926 in Turkey, which had 18 days. 162.158.154.64 13:04, 5 January 2024 (UTC)

Related insanity on Computerphile with Tom Scott: https://m.youtube.com/watch?v=-5wpm-gesOY Fabian42 (talk) 03:54, 14 December 2023 (UTC)

Even with just Special Relativity, the question doesn't really make sense, because the answer will depend on the inertial reference frame. "Impossible to know and a sin to ask" is not a bad way to describe questions about non-invariants. 162.158.154.189 08:09, 14 December 2023 (UTC)

Is it even possible for two observers to agree on the answer and be sure that it's correct for both of them? BunsenH (talk) 16:53, 14 December 2023 (UTC)
In order to know if the answer to T2 - T1 is correct, you'd first have to know if T1 and T2 are correct. I'd say that's already impossible. 172.71.99.134 11:53, 18 December 2023 (UTC)

I can see Randall's point, so for your average everyday programming I'd say "please use a library function instead of trying to do it yourself, or you'll end up like the guy in the lower frame..." --IByte (talk) 11:02, 14 December 2023 (UTC)

When I googled "DateTime" all I came up with was Python libraries, nothing about relativity or other effects. Is that what Randall's talking about? 172.69.22.125 22:03, 14 December 2023 (UTC)

Ideally, the standard library functions for a language would cover many of the "quirks" without the programmer having to worry about remembering the details. The required inputs for the functions would be sufficient to determine the necessary offsets. But programmers still have to be careful about some of the issues, and not all languages (and their libraries) are sufficient for all situations. When things like relativistic effects have to be taken into account, the usual languages (and their libraries) don't have the needed flexibility/complexity and precision. BunsenH (talk) 00:18, 15 December 2023 (UTC)
I should clarify, I'm not saying the Python library doesn't have functions for those quirks. I'm just asking: what does Randall mean when he says "DateTime" (two capital letters, no space, as per the comic title)? Is he talking about the Python library? Or something else I didn't find yet?172.69.134.163 02:51, 15 December 2023 (UTC)
Doesn't matter. For one the usage of CamelCase in such cases is pretty much standard regardless of language and besides of that the problems he's talking about/implying are pretty much true for every language. Elektrizikekswerk (talk) 10:58, 15 December 2023 (UTC)
OP, I suspect your Google cookies/whatever are just too used to serving you answers to Python questions, as being the answers you most like to visit. I just added to the "it's definitely Python" explanation another three more (of an easy dozen or so, before I gave up) links that I found from searches for "DateTime library <language>", or equivalent. And even those that didn't give that exact wording in their actual modules tended to have "What's the standard DateTime library for <foo>..?" as an FAQ (including LISP, Forth, COBOL, even a few for one or other Assembler variant, which I tried just for laughs) because the concept of "DateTime" record is just too ubiquitous (whether stored as "seconds since epoch" a distillation of an ISO format or just "[yy]yymmddHHMMSS[.###]" pseudo-value/string) and goes way back before Python (1991+) as you can find mentions of one kind or other in my old Ada (c1980) and Pascal (c1970) manuals/references. 172.70.162.206 15:47, 17 December 2023 (UTC)


The majority of libraries that provide time-calculation services call it something along the lines of DateTime. The reason you're getting Python results is because Python is currently the most popular programming language, especially for people learning to program. --172.71.150.154 19:51, 15 December 2023 (UTC)

The recently-added link for "hyperbolic" goes to a W'pedia page for "Hyperbolic motion (relativity)". This is obviously intended as a joke, but I'm not convinced that an unmarked joke like this is appropriate. BunsenH (talk) 16:04, 15 December 2023 (UTC)

I highly doubt this was meant as a joke, I'm quite convinced this was genuinely added to be helpful and fail to see how this COULD be a joke. ??? If it's not the correct concept it's too subtle to be a joke. NiceGuy1 (talk) 05:46, 17 December 2023 (UTC)
It quite definitely was a joke. I will take the badges of 'too subtle' and 'inappropriate' and wear them both with pride. ;o) 172.70.90.70 11:53, 3 January 2024 (UTC)

My first impression of the comic was that Randal was talking about romantic dates, and that participants may be too distracted to accurately recall when specific events occurred during them. These Are Not The Comments You Are Looking For (talk) 02:22, 17 December 2023 (UTC)