A year with 366 days is called a leap year. A year is a leap year if it is divisible by 4 (for example, 1980). However, since the introduction of the Gregorian calendar on October 15, 1582, a year is not a leap year if it is divisible by 100 (for example, 1900); however, it is a leap year if it is divisible by 400 (for example, 2000). Write a program that asks the user for a year and computes whether that year is a leap year. Implement a class Year with a predicate method boolean isLeapYear().

Complete the following file:

Year.java

Use the following file:

YearTester.java

public class YearTester
{
   public static void main(String[] args)
   {
      Year y = new Year(1980);
      System.out.println(y.isLeapYear());
      System.out.println("Expected: true");
      y = new Year(1900);
      System.out.println(y.isLeapYear());
      System.out.println("Expected: false");
      y = new Year(2000);
      System.out.println(y.isLeapYear());
      System.out.println("Expected: true");
      y = new Year(1500);
      System.out.println(y.isLeapYear());
      System.out.println("Expected: true");
      y = new Year(1501);
      System.out.println(y.isLeapYear());
      System.out.println("Expected: false");
   }
}