Advertisement
Guest User

Untitled

a guest
Dec 19th, 2014
155
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.26 KB | None | 0 0
  1. if(/* this is the largest */)
  2. {
  3.     //Look at the 'else' side to see why this works.
  4.     return left;
  5. }else
  6. {
  7.     //The largest is on my right, so if I update my right tree, then I'll be updated, and I can return myself.
  8.     right = right.removeLargestKey();
  9.     return this;
  10. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement