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...

what is the other ways to find a logic to print whether a
number is an even or odd wit out using % symbol??????? i
know three different ways to print it. so i need any other
different logic>>>>>

Answer Posted / govind279

#include<stdio.h>
main()
{
int x;
printf("Enter an ineteger ");
scanf("%d",&x);
if(x&0x1)
printf("Odd\n");
else
printf("Even\n");
}

Is This Answer Correct ?    7 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain how can I read and write comma-delimited text?

1154


I came across some code that puts a (void) cast before each call to printf. Why?

1199


Explain what would happen to x in this expression: x += 15; (assuming the value of x is 5)

1266


what is recursion in C

1056


The number of bytes of storage occupied by short, int and long are a) 2, 2 and 4 b) 2, 4 and 4 c) 4, 4 and 4 d) none

1231


Describe the difference between = and == symbols in c programming?

1350


What does dm mean sexually?

1298


Explain with the aid of an example why arrays of structures don’t provide an efficient representation when it comes to adding and deleting records internal to the array.

3132


Differentiate between #include<...> and #include '...'

1043


is it possible to create your own header files?

1091


Why is sizeof () an operator and not a function?

1012


How is a macro different from a function?

1155


What does s c mean on snapchat?

1090


Explain how do you declare an array that will hold more than 64kb of data?

1439


What is structure in c language?

1149