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 / aniket

#include <stdio.h>
#include <conio.h>

void main()
{
int year;
clrscr();

printf("\n\t : TO CHECK LEAP YEAR :");
printf("\n Enter your year : ");
scanf("%d", &year);

if((year % 4 == 0 && year % 100 != 0) || (year % 400 == 0))
{
printf("\n\a L E A P Y E A R");
}
else
{
printf("\n\a N O T L E A P Y E A R");
}
getch();
}

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What do you mean by dynamic memory allocation in c?

1153


Explain what is the purpose of "extern" keyword in a function declaration?

1127


What is wrong with this program statement? void = 10;

1316


What are the keywords in c?

1177


What is the difference between class and object in c?

1244


What should malloc() do?

1222


Explain what is the difference between a string and an array?

1227


Explain how can you avoid including a header more than once?

1148


Write a code to generate a series where the next element is the sum of last k terms.

1292


write a program that reads lines(using getline), converts each line to an integer using atoi, and computes the average of all the numbers read. also compute the standard deviation.

2575


In c programming typeing to occupy the variables in memory space. if not useing the variable the memory space is wasted.ok, how to avoid the situation..? (the variable is used & notused)

2176


Explain what is the difference between a string copy (strcpy) and a memory copy (memcpy)? When should each be used?

1149


What are structural members?

1066


Write the program with at least two functions to solve the following problem. The members of the board of a small university are considering voting for a pay increase for their 10 faculty members. They are considering a pay increase of 8%. Write a program that will prompt for and accept the current salary for each of the faculty members, then calculate and display their individual pay increases. At the end of the program, print the total faculty payroll before and after the pay increase, and the total pay increase involved.

3166


Tell me what is null pointer in c?

1133