Write a C language program to determine whether a number is odd or even.
#include<stdio.h>
#include<conio.h>
void main(){
int n;
printf("Enter number: ");
scanf("%d",&n);
if(n%2==0){
printf("%d is a Even number",n);
}
else{
printf("\n %d is a Odd number",n);
}
getch();
}
Input/Output:
Enter number: 5
5 is a Odd number
No comments
Dear Members, Thanks for Your Comments. We must be reply your comment answer as soon as possible. Please Stay with us.....