Date Coversion Routines
gordan
gordan at maccs.McMaster.CA
Thu Oct 20 11:09:30 AEST 1988
In article <483 at midgard.mn.org> dal at syntel.UUCP (Dale Schumacher) writes:
-In article <1483 at maccs.McMaster.CA> gordan at maccs.UUCP () writes:
-|
-|The two functions are astonishingly short, using some sort of floating
-|point trickery. They seemed to work when I tested them. Conversion to
-|C is left as an exercise for the reader.
-
-I don't think floating point is required. I know that it isn't for the
-formula that I have. I haven't compared the to closely enough (nor do I
[code omitted]
Yes, but the code you supply only does D/M/Y --> JD, not vice versa.
Believe it or not, there's a one-line Fortran statement that does
D/M/Y --> JD, which was also published in Sky & Telescope in 1984.
Actually it was the "vice versa" routine (JD --> D/M/Y) that did the
floating point.
More information about the Comp.lang.c
mailing list