This program is the first of the three programs that check whether the entered year is a leap year. This program doesn't check whether the number entered is a four digit number.
Just checks whether the number is divisible by four...
Yet another program to demonstrate the use of the Modulus Operator.
Any year is input through the keyboard.
Write a program to determine whether the year is leap year or not.
(Hint: Use the % (modulus) operator
printf ("Enter the year to be checked for validity as a Leap Year:");
scanf ("%d", &year);
printf ("The year is a Leap Year.\n");
printf("The year is not a Leap Year.\n");
The file can be found at: