Data Structures and Algorithms with Object-Oriented Design Patterns in C#
next up previous contents index

Withdraw Method

Program gif gives the code for the Withdraw method of the BinarySearchTree class. The Withdraw method takes as its argument the object instance to be removed from the tree. The algorithm first determines the location of the object to be removed and then removes it according to the procedure described above.

   program19205
Program: BinarySearchTree class Withdraw method.


next up previous contents index

Bruno Copyright © 2001 by Bruno R. Preiss, P.Eng. All rights reserved.