upper_bound
Description:
Gets the upper bound node corresponding to the given key, or null if the tree is empty or all the nodes in the tree have keys that are lower than or equal to the searched key.
The upper bound is the first node that has its key strictly greater than the searched key.
Parameters:
this |
a Tree |
key |
the key to calculate the upper bound for |
Returns:
the tree node corresponding to the upper bound, or null if the tree is empty or has only keys lower than or equal to the searched key. |