C Program to Check Whether a Number is Even or Odd
C Program to Check Whether a Number is Even or Odd
#include<stdio.h>
#include<conio.h> void main() { int a; printf("Enter the number a\n"); scanf("%d",&a); if(a==0) printf("0 is neither even nor odd"); else if(a%2==0) printf("The number %d is even",a); else printf("The number %d is odd",a); getch(); }