AVL Tree Balancing
问题 I am working on an assignment that asks me to implement an AVL tree. I'm pretty sure I have the rotation methods correct, but I'm having trouble figuring out when to use them. For example, the explanation in the book says that I should climb up the same path I went down to insert the node/element. However, I can't have any parent pointers. Latest code: public BinaryNode<T> insert(BinaryNode<T> node) { if (this.getElement().compareTo(node.getElement()) > 0) { if (this.getLeftChild() != null) {