No result found.

Outline

  • Leap year or not

Leap year checking (.net)

Varun Chouhan20 Feb, 2020

Leap year or not

        Using System;
namespace program
{
    Class leap
{
   static void main(string[]args)
   {
   console.write("Enter a year-");
   y=convert.ToInt32(console.Readline);
   if(y%4==0)&&(y%1001=0)||(y%100==0)
   {
     console.writeline("Leap year"+y);
   }
   else
   {
     console.writeline(y+"Not Leap year");
   }
     console.Readkey();
   }
 }
}