+ 1
Help, write program for to check even or odd number using else statement
4 Respostas
+ 6
1) take a number in an input
2) make an if else condition
3) in that condition, check if the remainder left when the number divided by 2 is zero or not, if it is, it is even coz it has no remainder left, otherwise it is odd.
+ 1
Specify the language
+ 1
int num;
cin>>num;
if(num%2==0) cout<<"Even Number";
else cout <<"Odd Number";
0
C++