Puzzled with Time Server conversion problems?
Bill Eldridge
bill at hk.rfa.org
Tue Oct 5 04:51:55 EDT 1999
Benjamin Schollnick wrote:
>
> From my experimentation is GMTIME:
>
> python GMTIME calcs RFC 868
> (Base 1970, Jan 1) (Base Jan 1, 1900)
> Jan 1, 1970 - 18,000.0 2,208,988,800
> Jan 1, 1976 - 189,320,400.0 2,398,291,200
> Jan 1, 1980 - 3,155,550,800.0 2,524,421,600
>
> I don't see how python's Jan 1, 1980 calcuation can exceed the RFC's
> calculation,
It can't. Your Jan 1, 1980 time has an extra 0:
>>> time.localtime(3155550800.0)
(1901, 12, 14, 4, 22, 28, 5, 348, 0)
>>> time.localtime(315555080.0)
(1980, 1, 1, 14, 11, 20, 1, 1, 0)
1970-1976 was about 190 million seconds, so 1976-1980 should
be less than double (380 million seconds), not 3.2 billion seconds.
--
Bill Eldridge
Radio Free Asia
bill at rfa.org
More information about the Python-list
mailing list