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

create an singly linked lists and reverse the lists by
interchanging the links and not the data?

Answer Posted / vimesh

struct node
{
int data;
node *link;
};
node *p=NULL;
void reverse(*x)
{
node *r,*s,*q;
r=NULL;
q=x
while(q->link!=NULL)
{
s=r;
r=q;
q=q->link;
r->link=s;
}
x=r;
}

Is This Answer Correct ?    2 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the types of queues?

1084


Why is bubble sort stable?

838


Why is data structure?

856


Define in brief an array. What are the types of array operations?

1189


What do you mean by the term “percolate down”?

895


Is hashset synchronized?

996


Explain binary searching, Fibonacci search.

940


Is arraylist heterogeneous?

872


What is the difference between a hashmap and hashtable?

807


What is difference between tree and forest?

882


What is inserting in data structure?

950


Which is the parent class of deque class?

919


What is the difference between hashset and arraylist?

970


State the different ways of representing expressions?

1204


What is data structure what is need of it?

880