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 / sanju uthaiah

#include<stdio.h>

int main()
{
char result[2]={"Even","Odd"};
int n=40;
printf("%d is %s",n,result[n%2]);
return 0;
}

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the scope of an external variable in c?

1050


Write a program, where i have a grid with many cells, how many paths are possible from one point to other desired points.

1242


What is the size of enum in c?

1121


What is keyword in c?

1017


Is c language still used?

987


What functions are used for dynamic memory allocation in c language?

1153


What is difference between stdio h and conio h?

1385


What is pointer and structure in c?

1193


how many errors in c explain deply

2096


What is the use of define in c?

1064


What is the difference between single charater constant and string constant?

1096


Is sizeof a keyword in c?

976


What language is windows 1.0 written?

1073


Explain what is the advantage of a random access file?

1126


What are called c variables?

1071