Take out a piece of paper and put your name on the upper right corner.
public class BinarySearchTree<E> {
private BinaryNode<E> root;
private Comparator<E> c;
public void insert(E e) {
// your code
}
private class BinaryNode<E> {
private E data;
private BinaryNode<E> left;
private BinaryNode<E> right;
}
}
Conduct a quick review of your code, before you are done.
After the code, write an explanation the Big-O performance of both methods.
Bonus point: implement the ArrayList’s E get(int index) method.
Hand in your code when you are done.
Time remaining: