This preview has intentionally blurred sections. Sign up to view the full version.View Full Document
Unformatted text preview: Binary T Definitio disjoint The bina A subtre binary t empty b The line subtrees Let t be We say of z and An item recursive ancesto in which Let t be If t is Trees on: A binar binary trees ary tree ee of a bina tree, the bin binary tree. e from a roo s are both e the followin that x is the d that z is th A is an anc ely, A is an r of B, the p h each item a binary tre empty, height( t ) = ry tree t is e s, called left is ry tree is its ary tree wh ot item to a mpty is calle ng binary tre e parent of he right child cestor of an ancestor of path from A in the seque ee, We defin-1 either empty subtree and different fro self a binary ose root ite subtree is c ed a leaf . A ee: y and y is t ld of x . n item B if B f B if A = p to B is the ence is the p ne height( t ), y or consists d right subt om the binar tree, and so em is B, the called branc leaf has no the left child B is an item parent(B) or sequence o parent of the the height o s of an item tree of t ....
View Full Document
- Fall '09