Write a c pgm for leap year
Answer Posted / rukmanee
#include<stdio.h>
#include<conio.h>
void main()
{
int year;
clrscr();
printf("\n enter a year:");
scanf("%d",&year);
if(year%2==0&&year%100==0&&year%400==0)
{
printf("the given year is a leap year");
}
else
{
printf("the given year is not a leap year :");
}
getch();
}
Is This Answer Correct ? | 4 Yes | 7 No |
Post New Answer View All Answers
What is null character in c?
What is meant by inheritance?
By using C language input a date into it and if it is right?
Is c language still used?
Is flag a keyword in c?
Explain which of the following operators is incorrect and why? ( >=, <=, <>, ==)
What is return in c programming?
Is it possible to have a function as a parameter in another function?
What are identifiers in c?
Write a Program to accept different goods with the number, price and date of purchase and display them
Explain the difference between strcpy() and memcpy() function?
What are pointers?
Is null equal to 0 in sql?
What is sizeof c?
write a C program:There is a mobile keypad with numbers 0-9 and alphabets on it. Take input 0f 7 keys and then form a word from the alphabets present on the keys.