C program to find leap year

C program to find leap year

A leap year is exactly divisible by 4 except for century years (years ending with 00). The century year is a leap year only if it is perfectly divisible by 400. Based on this concept, we write a program to find out whether a given year is a leap year or not. 

	Check if it is Leap Year
	Author 			: 		Krishna Teja G S
	Repository		:		github.com/packetprep/coding-questions
	Website			: 		packetprep.com


int main(){

	int number;

	printf("Enter the year: ");

	if( ((number % 4 == 0) && (number % 100 != 0))
			|| (number % 400 ==0) )
		printf(" %d is a Leap year\n",number);
		printf(" %d is not Leap year\n",number);

wipro free mock test
Wipro National Qualifier Test is just a few days away. To help you crack the exam we are sharing a mock test specially designed for Wipro based on all the previous papers.