Program No : 4 :

Write a program in C to check whether the given number even or odd ?

   program no  : 4
 purpose : check whether given number is even or odd number.

#include <"stdio.h">

void main()

{
	int number;
	
	scanf("%d", &number);

	if ( number % 2 ==1)
		 printf("odd");
	else
		 printf("even");

}  

Back