next up previous
Next: Up: Previous:

PreOrder

   PreOrder(x)
      if x <> NIL
      then print(key(x))
           PreOrder(left(x))
           PreOrder(right(x))

PreOrder traversal order: 5 2 1 4 10 8

Traversals


next up previous
Next: Up: Previous: