To install click the Add extension button. That's it.

The source code for the WIKI 2 extension is being checked by specialists of the Mozilla Foundation, Google, and Apple. You could also do it yourself at any point in time.

4,5
Kelly Slayton
Congratulations on this excellent venture… what a great idea!
Alexander Grigorievskiy
I use WIKI 2 every day and almost forgot how the original Wikipedia looks like.
Live Statistics
English Articles
Improved in 24 Hours
Added in 24 Hours
What we do. Every page goes through several hundred of perfecting techniques; in live mode. Quite the same Wikipedia. Just better.
.
Leo
Newton
Brights
Milds

Right rotation

From Wikipedia, the free encyclopedia

Right rotation refers to the following:

Tree rotation

In a binary search tree, a right rotation is the movement of a node, X, down to the right. This rotation assumes that X has a left child (or subtree). X's left child, R, becomes X's parent node and R's right child becomes X's new left child. This rotation is done to balance the tree; specifically when the left subtree of node X has a significantly (depending on the type of tree) greater height than its right subtree.

Right rotations (and left) are order preserving in a binary search tree; it preserves the binary search tree property (an in-order traversal of the tree will yield the keys of the nodes in proper order). AVL trees and red–black trees are two examples of binary search trees that use a right rotation.

A single right rotation is done in O(1) time but is often integrated within the node insertion and deletion of binary search trees. The rotations are done to keep the cost of other methods and tree height at a minimum.

References

  • Thomas H. Cormen, Charles E. Leiserson, Ronald L. Rivest, and Clifford Stein, 16 July 2001, Introduction to Algorithms, second edition. McGraw-Hill, ISBN 0-07-013151-1. Chapter 13.

This page was last edited on 21 March 2023, at 12:06
Basis of this page is in Wikipedia. Text is available under the CC BY-SA 3.0 Unported License. Non-text media are available under their specified licenses. Wikipedia® is a registered trademark of the Wikimedia Foundation, Inc. WIKI 2 is an independent company and has no affiliation with Wikimedia Foundation.