


Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!



Last time we outlined how to delete a node from a binary tree. We broke up our work into three cases:
5 15 ====> 7 15 (delete 7)
7 10 10 / \ /
5 15 ====> 7 12 (delete 12) / 12 10 10 / \ /
5 15 ====> 7 15 (delete 23)
23 In each of these two main cases, I am still glossing over a couple details:
In aiding the delete function, I have written several auxiliary functions: