Finding The Given Year Is Leap or Not In C Program


#include<stdio.h>
#include<conio.h>
void main()
{
	int year;
	clrscr();
	printf("\n Enter the Year :");
	scanf("%d",&year);		//www.tutorjoes.com
	year%100==0?(year%400==0?
	printf("\nGiven Year is Leap Year"):
	printf("\n Given Year Is Not a leap year")):
	(year%4==0?printf("\n Given Year is a Leap Year"):
	printf("\n Given Year IS Not an Leap Year"));
	getch():  //	(condition checking?Exp1:Exp2)
}

Login To Download Source Code

Leave a Comment:

Login To Comment

List Of Programs


Goto Examples

Operators

Looping

Number Conversion

Pattern Design

Arrays

Matrix Examples

Sorting Examples

String Function

Change Case

String In C

Maths Functions

User Defined Functions

Recursive Functions

Pointer

Structure

File Concept

Calender Programming