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 interchange two variables without using
the third variable?

Answer Posted / vinay tiwari

void main()
{
int a,b;
printf("enter two no ");
scanf("%d%d",&a,&b);
printf("a=%d and b=%d",a,b);
a=a^b;
b=a^b;
a=a^b;
printf("a=%d and b=%d",a,b);
getch();
}

Is This Answer Correct ?    22 Yes 13 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is %g in c?

1035


What does static variable mean in c?

1075


write a c program to find the largest and 2nd largest numbers from the given n numbers without using arrays

2199


Explain how many levels deep can include files be nested?

1041


any restrictions have on the number of 'return' statements that may be present in a function. a) no restriction b) only 2 return statements c) only 1 return statements d) none of the above

1104


Give basis knowledge of web designing ...

1992


Ow can I insert or delete a line (or record) in the middle of a file?

978


What is FIFO?

1572


What are dangling pointers? How are dangling pointers different from memory leaks?

1254


Tell me is null always defined as 0(zero)?

1053


Explain the difference between structs and unions in c?

980


What are categories used for in c?

1052


Is javascript based on c?

1023


What is difference between stdio h and conio h?

1336


What is the size of array float a(10)?

1107