make a middle node of doubly linklist to the top of the list
Answer Posted / hussein
middle->prev->next = middle->next;
middle->next->prev = middle->prev;
// Now make the middle as head.
middle->prev = NULL;
middle->next = head;
head->prev = middle;
head = middle;
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
What is the keyword auto for?
Do you know the use of vtable?
Explain the different access specifiers for the class member in c++.
What are c++ redistributables?
What is the best way to declare and define global variables?
what is C++ exceptional handling?
What is pure virtual function? Or what is abstract class?
What is c++ prototype?
Explain the purpose of the keyword volatile.
What are manipulators in c++ with example?
How can you create a virtual copy constructor?
What are disadvantages of pointers?
give me an example for testing a program showing the test path .show how the test is important and complex.
Define friend function.
How would you use the functions randomize() and random()?