Given the declarations in Exercise 13, and the fact that the first node has been inserted into the list as in Exercise 14, write a code segment that creates a new node with the component value equal to 212 and inserts this node at the end of the list, updating any pointers as necessary.
Exercise 13
Given the dynamic linked implementation of a linked list shown below, write expressions that do the following, assuming that currPtr is somewhere in the middle of the list:
a. Access the component member of the first list element.
b. Advance currPtr to point to the next element.
c. Access the component member of the next element (the one that follows the current element).
d. Access the component member of the element that follows the next element.
typedef int ComponentType;struct NodeType;typedef NodeType* NodePtr;struct NodeType{ ComponentType component; NodePtr link;}NodePtr lastPtr;NodePtr listPtr;NodePtr currPtr;NodePtr newNodePtr;Exercise 14
Given the declarations in Exercise 13, write a code segment that creates a new node, assigns the value 100 to the component member, links listPtr to the new node, and sets currPtr to also point to the node.
We need at least 10 more requests to produce the solution.
0 / 10 have requested this problem solution
The more requests, the faster the answer.