Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Write a c pgm for leap year

Answer Posted / kumari rina

#include<stdio.h>
#include<conio.h>
void main()
{
int n;
clrscr();
printf("\n enter the year");
scanf("%d",&n);
if(n%100==0)
{
if(n%400==0)
{
printf("\n year is leap year");
}
else
{
printf("\n year is not leep year");
}
}
else
{
if(n%4)
{
printf("\n year is leap year");
}
else
{
printf("\nyear is not leap year");

}
}
getch();
}

Is This Answer Correct ?    12 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What do you mean by a local block?

1087


How does pointer work in c?

1124


How can I open a file so that other programs can update it at the same time?

1187


Why doesn't C support function overloading?

2763


What language is windows 1.0 written?

1064


Is return a keyword in c?

1086


What is a null string in c?

1039


Explain goto?

1156


Why doesnt this code work?

1061


What's the difference between constant char *p and char * constant p?

1151


Explain what are binary trees?

1077


Explain the difference between getch() and getche() in c?

998


Devise a program that inputs a 3 digit number n and finds out whether the number is prime or not. Find out its factors.

1121


Why doesnt that code work?

1176


What is a lookup table in c?

1120