Leap year in Java

A leap year is a 366-day year, which is one day longer than a normal year. This additional day comes is in February, where February is 29 days compared to…