Add new comment

Permalink

Your method is far too complicated.

Thurs, 25 May 1961 to *day 20 July 1969

Years are 52 weeks and a day, leap years are 52 weeks and 2 days, and since days of the week recycle every week we can ignore weeks entirely.
six standard years (6 days) + 2 leap years (4 days) = 10 days ... ignore 1 week (7 days) = 3 days
1* 31 day month (4 weeks & 3 days) ... ignore 4 weeks = 3 days
1* 30 day month (4 weeks & 2 days) ... ignore 4 weeks = 2 days
subtract 5 days (25th - 20th)

3+3+2-5 =3 days

3 days after Thursday = Sunday

... far easier than trying to multiply up to 2,978 then dividing down to 425, and a bit

Filtered HTML

  • Web page addresses and email addresses turn into links automatically.
  • Allowed HTML tags: <a href hreflang> <em> <strong> <cite> <code> <ul type> <ol start type> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.