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 2 chars without using a third
varable?
char *s = "A";
char *p = "B";

Answer Posted / s.divya

void swap(A,B)
{
A=*p;
B=*s;
getch();
}

Is This Answer Correct ?    1 Yes 18 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the benefits of operator overloading?

1220


What is the difference between an array and a list?

1035


When should overload new operator on a global basis or a class basis?

1081


When does the c++ compiler create temporary variables?

1051


What is the difference between interpreters and compilers?

1193


Is vector a class in c++?

1051


Specify some guidelines that should be followed while overloading operators?

1213


Which is best ide for c++?

1014


What is the difference between the functions memmove() and memcpy()?

1123


what are function pointers?

1065


What is the role of static keyword for a class member variable?

1074


Tell me can a pure virtual function have an implementation?

1034


what are Access specifiers in C++ class? What are the types?

1236


What is setw manipulator in c++?

1085


Is there a sort function in c++?

1006