2. Draw ,flowchart and write a
program that take any integer from user
and check weather it is even or not.
Hint: use if else
Question # 2
#include
#include
void main()
{
int a;
clrscr();
printf("Please
Enter any number:");
scanf("%d",&a);
if(a%2==0)
printf("\nEVEN");
else
printf("\nODD");
getche();
}
No comments:
Post a Comment