Lecture 24
Learning objectives
After this class, you should be able to:
- Formally prove properties of different types of trees and algorithms on them.
- Formally prove that algorithms with certain time complexities are impossible, using the fact that comparison-based sorting cannot be done faster than
Theta(n log n)
time.
Reading assignment
- Class notes.
Exercises and review questions
- Exercises and review questions on current lecture's material
- Prove that if a node
x
has a right child, then the successor of x
must be the smallest valued node in the right subtree of x
.
- Prove that if a node
x
has no right child, then the successor of x
must be one of the ancestors of x
, if x
has a successor.
- Prove that a rotation preserves the BST property.
- Prove that it is impossible to develop a
O(n)
time BST initialization algorithm.
- Prove that it is impossible to develop a
O(1)
time AVL tree insertion algorithm.
- Questions on next lecture's material
- None. Please work on assignment 6.
Last modified: 16 Nov 2004