The following lines talks about deleting a node in a binary tree.(the tree property must not be violated after deletion)
i) from root search for the node to be deleted
ii)
iii) delete the node at
what must be statement ii) and fill up statement iii)
(a) ii)-find random node,replace with node to be deleted. iii)- delete the node
(b) ii)-find node to be deleted. iii)- delete the node at found location
(c) ii)-find deepest node,replace with node to be deleted. iii)- delete a node
(d) ii)-find deepest node,replace with node to be deleted. iii)- delete the deepest node
Enquiry is from Binary Trees using Linked Lists in chapter Binary Trees of Data Structures & Algorithms I
The question was asked during an online interview.