next up previous
Next: Successor(n) Up: CSE 2320: Algorithms and Previous: Successor(n)

Successor(n)

right(n) = NIL
Case II: Find s such that left(s) is n or an ancestor of n


\psfig{figure=figures/f6-7.ps}

Try n=5



Case III: No such ancestor exists; thus, no successor
Try n=7



Copyright © 1998 The University of Texas at Arlington