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

#include main() { char s[] = "Bouquets and Brickbats"; printf(" %c, ",*(&s[2])); printf("%s, ",s+5); printf(" %s",s); printf(" %c",*(s+2)); }

0 Answers   Wilco,


#include<stdio.h> int SumElement(int *,int); void main(void) { int x[10]; int i=10; for(;i;) { i--; *(x+i)=i; } printf("%d",SumElement(x,10)); } int SumElement(int array[],int size) { int i=0; float sum=0; for(;i<size;i++) sum+=array[i]; return sum; } output?

5 Answers   Ramco,


What is the difference between procedural and functional programming?

0 Answers  


What is struct node in c?

0 Answers  


Why is c known as a mother language?

0 Answers  






What is sizeof array?

0 Answers  


what is the meaning of 'c' language

3 Answers  


Explain about block scope in c?

0 Answers  


What is size of union in c?

0 Answers  


Suggesting that there can be 62 seconds in a minute?

0 Answers  


Write code for initializing one dimentional and two dimentional array in a C Program?

5 Answers   Deshaw, Edutech, GMD,


wat is the difference between array and pointer?

4 Answers   Wipro,


Categories