Two Deletions with Successor Replacement

A database index uses the binary search tree shown. Delete key 5252, then delete key 6868 from the resulting tree. Whenever the deleted node has two children, use its inorder successor as the replacement key. Remove the successor from its original position and reconnect any right child it has. Do not rebalance the tree.


After both deletions, report the root key, the key of the parent of 6464, and the total number of remaining nodes. Give all three answers as exact integers.


A binary search tree contains twelve keys with several levels in its right subtree.


Your answers

Create a free account to get started

Unlock full course notes by signing up

  • Video lessons taught by top educators
  • Practice questions with guided solutions
  • Written review notes for reference
  • Expert answers anytime from course tutors

More Binary Search Trees Questions: