find whether the given number is even or odd
/*
Developed by deepak anand.
For more programs,
visit programming-stuff-4-u.blogspot.in
*/
//WAP to find whether the given number is even or odd.
#include<stdio.h>
#include<conio.h>
void main()
{
int num;
clrscr();
printf("Enter the number\n");
scanf("%d",&num);
//logic part
if(num%2==0)
printf("Given number is Even");
else
printf("Given number is odd");
getch();
}
No comments:
Post a Comment