Show that every n-node binary search tree is not equally likely (assuming items are inserted in random order), and that balanced trees are more probable than straight-line trees.
How is it prove mathematical?
Please, help
Show that every n-node binary search tree is not equally likely (assuming items are inserted in random order), and that balanced trees are more probable than straight-line trees.
How is it prove mathematical?
Please, help
Hint
Take a look at the Geometric Distribution and use $p=0.5$.