Question: I) For the following declaration, write the codes as asked. The pointer variable first points to the first node of the linked list. Each
I) For the following declaration, write the codes as asked. The pointer variable first points to the first node of the linked list. Each node has data member that stores the data and the next member that stores the address of the next node Given the declaration: first struct Node { int data; Node *next; }; Write C++ code using a while statement to print all the data members of the nodes starting from prt1 to prt2 (number of nodes between ptr1 and ptr2 are not given) in the displayed linked list. ptr1 (Only provide the partial code not whole function) ptr2
Step by Step Solution
3.41 Rating (160 Votes )
There are 3 Steps involved in it
OUTP... View full answer
Get step-by-step solutions from verified subject matter experts
