...

/

Solution: Random Binary Search Trees

Solution: Random Binary Search Trees

Review the solution that implements a treap from a sorted array.

We'll cover the following...

Task

Here is the solution that implements an algorithm that constructs a Treap from a sorted array, a, of n elements. This method runs in O(n)O(n) worst-case time and should construct a Treap that is indistinguishable from ...