how to make program for convet normal date to Julian date | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 2

how to make program for convet normal date to Julian date

programmingin c or c++

7th Jun 2017, 5:35 PM
paresh jaisinghani
1 Answer
+ 9
Well, you'd first need to look up a reference date for the conversion (I don't know it offhand). Then count the days from the reference to the date in question (and make sure you track if you're going forward or backward). Then you need to create the fractional portion, divide the hours/minutes/second by how many of each there are in a day. Then it should just be a matter of addition our subtraction, which is why MJD is so handy. There are converters out on the web for you to compare against, I'm sure. Good luck!
7th Jun 2017, 11:39 PM
Jim
Jim - avatar