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 reverse a linked list?

Answer Posted / bipin pandey

node *reverse(node *first)


{
node *cur,*temp;


cur=NULL;

while(first!=NULL)


{temp=first;

first=first->link;

temp->link=cur;

cur=temp;
}

return cur;

}

Is This Answer Correct ?    5 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is searching? Explain linear and binary search.

998


Why c++ is faster than java?

1064


What are the various arithmetic operators in c++?

1132


What are the 2 main types of data structures?

1125


Do you know what are pure virtual functions?

1152


an operation between an integer and real always yeilds a) integer result b) real result c) float result

1160


Why c++ is called oop?

1129


What does it mean to declare a destructor as static?

1086


What is constructor c++?

1120


what are the decision making statements in C++? Explain if statement with an example?

1099


What are the advantage of using register variables?

1174


What is c++ runtime?

1115


Define pure virtual function?

996


Where Malloc(), Calloc(), and realloc() does get memory?

1057


Write about an iterator class?

1087