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

how to swap two integers 1 and 32767 without using third
variable

Answer Posted / vidhubala-j

int a=1
int b=32767
a^=b^=a
printf("%d %d",a,b);

Is This Answer Correct ?    4 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Do you know what are bitwise shift operators in c programming?

1109


WRITE A PROGRAM TO MERGE TWO SORTED ARRAY USING MERGE SORT TECHNIQUE..

2089


In c language can we compile a program without main() function?

1142


What is meant by gets in c?

1197


How do you declare a variable that will hold string values?

1183


What are the rules for the identifier?

1171


What is define directive?

1160


What is the use of static variable in c?

1093


plz let me know how to become a telecom protocol tester. thank you.

2191


Explain the use of #pragma exit?

1181


What is the difference between malloc calloc and realloc in c?

1150


What is scope rule in c?

1075


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

1246


Explain what is the difference between text files and binary files?

1164


Write program to remove duplicate in an array?

1089