# C program to check Even orOddusingBitwiseOperator

## C program to check Even orOddusingBitwiseOperator

This page has a C program to check Even or Odd using Bitwise Operator. Even number is an integer number which can be dividable by 2. The remainder after division of an even number by 2 is zero. For examples: The Even numbers are 0, 2, 4, 6, 8, . . . Odd number is an Integer number which can not be dividable by 2. The remainder after division of an Odd number by 2 is one. For examples: The Odd number are 1, 3, 5, 7, 9, 11, 13, . . .  The below given C program is used to check whether a number is Even or Odd using Bitwise Operator. Kindly check out the Even or Odd using Bitwise Operator. The Even or Odd program can be asked in various ways for school and college going students. The question of Even or Odd program may be as

1). Write a C program to check whether the given number is odd or even using Bitwise Operator.

2).Write a C program to check whether the given number is even or odd using Bitwise Operator.

3). Write a C program check even or odd using if else and Bitwise Operator.

### Even or Odd Program using Bitwise Operator

#include<stdio.h>
int main(){
int num,rem;
clrscr();
printf(" Enter an integer number: ");
scanf("%d",&num);
rem = num & 1; //Bitwise Operator & used
if(rem == 0)
printf("\n %d is an even number.",num);
else
printf("\n %d is an odd number.",num);
getch();
return 0;
}

### Sample outputs:

Enter an integer number: 13

13 is an odd number.

Enter an integer number: 674

674 is an even number.