Question: im having trouble with this assignment in C++ the top pictore is the requirments and the bottom is the start i was given thank you
im having trouble with this assignment in C++ the top pictore is the requirments and the bottom is the start i was given thank you for your help

DoublyLinked List Hide Folder Information Instructions Implement DoublyLinked List. : each node contains two pointers: one to the next node in the list, one to the previous node in the list Refer the attached file to define the DoublyLinkedList. Implement the following operations 1. add a node in the end of the list 2. add a node in the beginning of the list 3. Display the list contents forward 4. Display the list content backwards. Start Date class DLinklist { private: //define each node in the list struct DLLNode { int value; //store value in the node struct DLLNode *next; //pointer to the next node struct DLLNode *prev; //pointer to the previous node }; DLLNode *head, *tail; int nodeCount; public: DLinkList() { head = nullptr; tail nullptr; nodeCount = 0; } -DLinklist();//destructor //add a function that appends nodes in the end of list void add_end(int); void add_begin(int);//inserts a new node in the start position 2);//inser void display_forward(); //display the contents in the list void display_back();//display the contents in the list }
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
