Input: # of seconds since January 1st, of Year 0001
Output: # of Full years during this time period
I have developed an algorithm that I do not think is the
I think that this will work for you:
function foo(days): count = days year = 0 while (count > 0): if leap_year(year) count = count - 366 else count = count - 365 year ++ return year