on Sep 5th, 2016, 09:47am, pnlawrence wrote:| Wasn't that the year that we were all supposed to be slung off the Earth never to be heard from again? |
|
In all seriousness this conditional test in Jack's program is surprising:
Code:if yyyy mod 4 = 0 and yyyy<>2000 then
It was/is quite fortuitous that 2000 (being a multiple-of-400 year) fitted in with the simple leap-year rule because it meant that programs written carelessly, or with an expectation that they wouldn't still be in use by then, nevertheless worked correctly. But there's no accounting for somebody inserting a special test for 2000, when it wasn't special!
If the test had said year<>2100 it would have been correct, and we would have been congratulating Jack for his optimism!
Richard.