Integers which are perfectly divisible by 2
are called even numbers. And those integers which are not perfectly
divisible by 2 are not known as odd number. To check whether an integer
is even or odd, the remainder is calculated when it is divided by 2
using modulus operator %. If remainder is zero, that integer is even if not that integer is odd.
#include <iostream>
using namespace std;
int main() {
int n;
cout << "Enter an integer: ";
cin >> n;
if ( n%2 == 0) {
cout << n << " is even.";
}
else {
cout << n << " is odd.";
}
return 0;
}
Output
Enter an integer: 23 23 is odd.
1 comment:
Do you need to increase your credit score?
Do you intend to upgrade your school grade?
Do you want to hack your cheating spouse Email, whatsapp, Facebook, instagram or any social network?
Do you need any information concerning any database.
Do you need to retrieve deleted files?
Do you need to clear your criminal records or DMV?
Do you want to remove any site or link from any blog?
you should contact this hacker, he is reliable and good at the hack jobs..
contact : cybergoldenhacker at gmail dot com
Post a Comment