Answered step by step
Verified Expert Solution
Question
1 Approved Answer
can you guys please help me with these questions thank you 9.Given a Double Linked-List that contains the values in order: 1,2,3,4,5; and the following
can you guys please help me with these questions thank you 9.Given a Double Linked-List that contains the values in order: 1,2,3,4,5; and the following class declarations: class List private: Node* head; public: PrintBackwards (); class Node{ friend class List; private: int value; Node* next; Node* prev; Write the algorithm PrintBackwards that prints the whole list backwards. So your functionshould output: 5,4,3,2,1" Extra Credit if you instead implement the algorithm for a single linked-list (i.e. only using the Node* next pointer). You may change the function declaration if necessary. b. What is the Big-Oh runtime of the function you created? 10. Using the Double Linked-List from Question 9, and given the Algorithm header below: Algorithm RemoveNodeAtValue( value) input integer value to be removed output none Write the C++ implementation of this Algorithm b. What's the Big-Oh runtime of your Algorithm
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started