We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Learning-JavaScript-Data-Structures-and-Algorithms-Third-Edition/LearningJavaScriptDataStructuresandAlgorithmsThirdEdition_Code/src/ts/data-structures/avl-tree.ts
Line 181 in 2cedcaf
return this.rotationLR(node);
Why use left?
The text was updated successfully, but these errors were encountered:
Learning-JavaScript-Data-Structures-and-Algorithms-Third-Edition/LearningJavaScriptDataStructuresandAlgorithmsThirdEdition_Code/src/ts/data-structures/avl-tree.ts Line 181 in 2cedcaf return this.rotationLR(node.left); I think this line should be: return this.rotationLR(node); Why use left?
I think this line should be:
Hi,canfeit!
The author is correct,the function of rotationLR params is node.left not node, why ? maybe you should review rotationLR Function details.
node.left
node
first, use node.left rotate to the left, node.left.right get balanced second, use node rotate to the right, node.left get balanced
rotationLR(node) { node.left = this.rotationRR(node.left); return this.rotationLL(node); }
Sorry, something went wrong.
No branches or pull requests
Learning-JavaScript-Data-Structures-and-Algorithms-Third-Edition/LearningJavaScriptDataStructuresandAlgorithmsThirdEdition_Code/src/ts/data-structures/avl-tree.ts
Line 181 in 2cedcaf
I think this line should be:
Why use left?
The text was updated successfully, but these errors were encountered: