View Single Post
Old Dec 8th, 2005, 11:33 PM   #3
The Dark
Expert Programmer
 
Join Date: Jun 2005
Posts: 852
Rep Power: 4 The Dark is on a distinguished road
juliocarlosmg: I think the big -- Closed -- text was meant to indicate that the OP didn't need any more answers.

In addition to this your CountDays function does not work. If you give it two dates with the year value less than 4 apart, it will never think there is any leap years in between them.
E.g. 2000/01/01 - 2001/01/01

I don't think you can use the difference between two years to determine the number of leap years, because once you subtract one from the other, you lose the information about whether either year was a special case (i.e divisible by 100 or 400).
The Dark is offline   Reply With Quote