JAVA Program to Check whether a year is Leap year or not

This Java programming tutorial will teach you the methods for writing program to A Year is Leap Year or Not.

class CheckLeapyear
{
public static void main(String[] args)
{
int n=2012;
if (n%4==0){
System.out.println(“This is a leap year”);
}
else{
System.out.println(“This is not a leap year”);
}
}
}