On Thursday, September 19, 2019 at 7:39:47 AM UTC-7, Thomas Keffer wrote:

> I'm in favor of eliminating month arithmetic. It doesn't add anything.
>
>
Wow there are a lot of edge cases. Graham's experiment makes my head spin.

Perl does it this way - 
https://metacpan.org/pod/DateTime#$dt-%3Esubtract_datetime(-$datetime-)

I particularly liked the "*Note that this duration is not an absolute 
measure of the amount of time between the two datetimes, because the length 
of a month varies, as well as due to the presence of leap seconds.*"

There doesn't seem to be a great answer on this one that doesn't get really 
complicated.

-- 
You received this message because you are subscribed to the Google Groups 
"weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/7086c963-6b87-48c1-8ad8-04be4ecb8e97%40googlegroups.com.

Reply via email to