C++ Program to check Leap Year

ad+1

Program:

// Program By http://solutionscpp.blogspot.com
// Author Mansoor Ahmed
// GMail ID: secguy000@gmail.com

#include<iostream>
using namespace std;

int main()
{
    int year=0;
   
    cout<<"Enter Year: ";
    cin>>year;
   
    if(year%4==0)
    cout<<"Entered Year is a Leap Year" <<endl;
   
    else
    cout<<"Entered Years is NOT a leap year" <<endl;
   
    return 0;
 
 }

Output:

0 comments: