* Double rotate binary tree node: first left child. * with its right child; then node k3 with new left child. * For AVL trees, this is a double rotation for case 2. * Update heights, then set new root. */voiddoubleWithLeftChild( AvlNode * & k3 ) {rotateWithRightChild( k3->l...
rotateRight(node);// AVL left left }else{ assert(leftDelta==-1); rotateRight(node); 代码示例来源:origin: at.bestsolution.efxclipse.eclipse/com.google.gson rotateRight(right);// AVL right left rotateLeft(node); rotateRight(node);// AVL left left }else{ assert(leftDelta==-1); rotateRi...