x LChild-Data
Height(AT-LChild) - Height(AT-RChild) == 2
No
Yes
AT = DoubleRotateWithLeft(AT)
x AT-RChild-Data
AT = SingleRotateWithRight(AT)
AT = SingleRotateWithLeft(AT)
AT-Data = x
AT==null
AT = (AVLTree)malloc(sizeof(AVLNode))
AT-Height = 0
AT = DoubleRotateWithRight(AT)
AT-RChild = NULL
AT-LChild = NULL
x Data
AT == NULL
Start
End