InterviewSolution
Saved Bookmarks
| 1. |
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 deletedii)iii) delete the node atwhat 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 nodeEnquiry is from Binary Trees using Linked Lists in chapter Binary Trees of Data Structures & Algorithms IThe question was asked during an online interview. |
|
Answer» The correct option is (d) ii)-find deepest node,REPLACE with node to be DELETED. III)- DELETE the deepest node |
|