- Binary search trees support all of the dynamic set operations
mentioned before. In the worst case, each operation
takes O(n) time on a tree with n elements.
- Red-black trees are a variant of binary search
trees that are self-balancing. In
the worst case, each operation
takes O(log n) time on a tree with n elements.
- Binary heaps can perform priority queue
operations (insert, remove, minimum, maximum) in O(log n)
for a queue with n elements.
- Hash tables can perform dictionary operations
(insert, remove, search) in O(1)
(constant) time.