What are Even numbers?
A number which is evenly divisible by 2 is called an even number. It means when you will divide even number by 2 then the remainders will be zero.
For example, 2, 4, 6, ..etc
What are the Odd numbers?
If a number that is not evenly divisible by 2 is called an odd number.
C program to find even and odd numbers
1. Using the if-else condition:
2. Using the ternary condition:
3. Using the bit-wise operators:
We can also check even-odd numbers by checking LSB bit. If the LSB bit of a number is set that means odd number otherwise even.