0
Why Leap year are divisible by 4 is not sufficient condition
4 Antworten
+ 1
if(leap%4==0)
//leap year
else
//not leap year
+ 1
because earth rotates 366.25041 days a year
0
Years 1700, 1800, 1900, 2100, 2200, 2300, 2500, 2600 are not leap years even thought they are divisible by four. So if only "year%4==0" is given as condition the above mentioned year will be shown as leap years. So we have to check if they are divisible by 400.
Years ending with 00 are leap years only if it is divisible by 400
Please Upvote :)
0
for century it must devided by 400 and other than century devided by 4.