Returns/ the first element. Complexity: O(1)
Inspired by @mxcl 's tweet
Returns the last element. Complexity: O(1)
Performs a right rotation on the tree
Performs a left-right rotation
Rebalances the tree below the node if the height differences are too big
Removes a node from the tree. Reports the removed value in the reporter object
the new root
Generator function that returns all the values of the nodes below and this in an descending order
Performs a right-left rotation
Performs a right rotation on the tree
Calculates the height of the node. A leafs (node without either a left or a right node) height is
Generated using TypeDoc
Generator function that returns all the values of the nodes below and this in an ascending order