Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

find a number whether it is even or odd without using any
control structures and relational operators?

Answer Posted / rohit agarwal

#include<stdio.h>
#include<conio.h>
main()
{
int n;
char *p[]={"Even","odd"};
clrscr();
printf("Enter the number");
scanf("%d",&n);
n=n%2;
printf("The value is %s",p[n]);
getch();

Is This Answer Correct ?    1 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is an example of structure?

1038


how to build a exercise findig min number of e heap with list imlemented?

2068


What is logical error?

1114


What does the error message "DGROUP exceeds 64K" mean?

1215


What do you mean by invalid pointer arithmetic?

1067


What are void pointers in c?

991


The __________ attribute is used to announce variables based on definitions of columns in a table?

1193


Explain what’s a signal? Explain what do I use signals for?

1145


What is the best way to store flag values in a program?

1068


How do we declare variables in c?

1056


Explain logical errors? Compare with syntax errors.

1068


how to construct a simulator keeping the logical boolean gates in c

2251


What is difference between far and near pointers?

1033


What is structure in c language?

1160


What is anagram in c?

909