General

Check Whether Number is Even or Odd in C++1 min read

In this C++ example, we’ll learn How to check whether number is even or odd.

if…else statement is used to check whether a number entered by the user is even or odd.

C++ Code:




Output:

Leave a Comment