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

write a program to swap Two numbers without using temp variable.

Answer Posted / ashish omar

Suppose: a = 3
b=2;

11
10
a = a ^ b;

11
10
==
01

b = a ^ b;
01
10
==
11

a = a ^ b;

01
11
==
10

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between the local variable and global variable in c?

931


What is p in text message?

938


Should a function contain a return statement if it does not return a value?

1024


Differentiate between full, complete & perfect binary trees.

1055


Can you think of a logic behind the game minesweeper.

2421


A SIMPLE PROGRAM OF GRAPHICS AND THEIR OUTPUT I WANT SEE WAHAT OUTOUT OF GRAPHICS PROGRAM

2080


What is use of null pointer in c?

963


What is c programing language?

1047


Why c is called free form language?

972


Why do we use main function?

1116


Why array is used in c?

975


Process by which one bit pattern in to another by bit wise operation is?

1102


When c language was developed?

1012


What is static identifier?

1172


What is array in C

1102