Wednesday 18 December 2013

PROGRAM TO FIND LEAP YEAR USING C++


/*THIS PROGRAM CHECKS WHETHER THE
ENTERED YEAR IS LEAP OR NOT*/

#include<iostream.h>
#include<conio.h>
void main()
{
 int n;
 cout<<"enter the year";
 cin>>n;
 if(n%4==0)
 {
  cout<<"entered year is leap year";
 }
 else
 {
  cout<<"the entered year is not leap year";
 }
 getch();
}

1 comment: