Quote (ferf @ Oct 10 2018 03:00am)
Code
if(isLeapYear(year))
Where does it go in first method... what condition is it testing?
you have the function above
February has different days in the month depending on the type of the year.
From wikipedia
if (year is not divisible by 4) then (it is a common year)
else if (year is not divisible by 100) then (it is a leap year)
else if (year is not divisible by 400) then (it is a common year)
else (it is a leap year)
The function is just testing those to check weather the year in question is a common or a leap year! Feel free to pm me if you still have doubts!