C++ Programming Blog

 
 
 

Image

 #include<iostream.h>
 #include<conio.h>


 main()
    {
       clrscr();

       int year;

       cout<<\"\\n Enter the year = \";
       cin>>year;

       if(year%4==0 || year%400==0 || year%100==0)
      cout<<\"this is a leap year\"<<endl;

       else
      cout<<\"this is not a leap year\"<<endl;

       getch();
       return 0;
    }

 
 
Didn't find what you were looking for? Find more on Program to find whether a year is a leap year or not