Solved

To Remove a Node with a Positive Index K from a Linked

Question 31

Multiple Choice

To remove a node with a positive index k from a linked list,


A) decrement k by 1,and set the reference to the node to be removed to null
B) start a reference r at the head of the list,walk r forward k steps,and then set r to null
C) assign the successor reference in the node with index k to the successor reference in the node with index k-1
D) decrement k by 1,and then use recursion

Correct Answer:

verifed

Verified

Unlock this answer now
Get Access to more Verified Answers free of charge

Related Questions