Write a pro-gramme to determine whether the number is even or odd?



Write a pro-gramme to determine whether the number is even or odd?..

Answer / azad sable, chiplun

void main();
{
int n;
clrscr();
printf("enter any number");
scanf("%d",&n);
if(n%2==0)
printf("\nthe number is even");
else
printf("\nthe number is odd");
}
getch();
}

Is This Answer Correct ?    5 Yes 0 No

Post New Answer

More C Interview Questions

What are the usage of pointer in c?

1 Answers  


HOW TO ANSWER IF ASKED " WHAT KIND OF A PERSON ARE YOU?" I NEED AN ANSWER THAT IMPRESS THE INTERVIEWER

4 Answers  


Which is not valid in C? 1) class aClass{public:int x;} 2) /* A comment */ 3) char x=12;

7 Answers  


Explain what does a function declared as pascal do differently?

1 Answers  


How many keywords are there in c?

1 Answers  


Why pointers are used in c?

1 Answers  


what does exit() do?

3 Answers   Cadence,


What is the process to create increment and decrement stamen in c?

1 Answers  


How to write a multi-statement macro?

1 Answers  


What are reserved words with a programming language?

1 Answers  


what is a c-language.what is do.

4 Answers   HCL,


Explain the properties of union.

1 Answers  


Categories