next up previous
Next: Up: Previous:

Rotate

   Left-Rotate(T,x)
      size(y) = size(x)
      size(x) = size(left(x)) + size(right(x)) + 1

   Right-Rotate(T,x)
      size(x) = size(y)
      size(y) = size(left(y)) + size(right(y)) + 1


next up previous
Next: Up: Previous: