Even Odd Program in C++

In this C++ Programming tutorial we will see a Even Odd Program in C++ which checks whether a given number is Even or Odd. We will take the input number from the user and use the % (modulo) operator to check if the entered number is divisible by 2 or not in the if condition. If it is true we will print Even Number else we will print Odd Number.

Even Odd Program in C++
Output
Enter an integer: 5
5 is odd.

Leave a Reply

Your email address will not be published. Required fields are marked *