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 numbers in a linked list without exchanging
the data but only the links?

Answer Posted / sha

let q=20,r=10 and p be a node previous to q
sequence is p-q-r
temp is pointer of link list.
then
temp=p->next;
p->next=temp->next;
p->next->next=temp;
and temp next can be conected to p->next->next->next if
there is any

Is This Answer Correct ?    4 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the stl, standard template library?

1143


what is template and type convertion

2494


What is a stl vector?

1373


How do you convert stl to steps?

1210


Why should a c++ programmer be interested in stl?

1152


draw a flowchart that accepts two numbers and checks if the first is divisible by the second.

3431


What is stl in c++ with example?

1218


totoo po ba ang manga aliens!

2833


help me i need a c++ program which takes sequesnce of characters and outputed sequence of their token taypes, work same compiler in lexical analysis phase

2434


What are stl algorithms?

1219


a program using one dimensional array that searches a number if it is found on the list of given input numbers given by the user and locate its exact location in the list.

2032


sir please send me bpcl previous question papers

2462


What two types of containers does the stl provide?

1042


How stl is different from the c++ standard library?

1287


Is stl open source?

1189