Update RankNode.java

Initially the tree starts off with a smaller number like 30 and then a big number like 95 is inserted and its rank is updated soon after. After that if a sequence of smaller numbers like 20, 25, 30 etc., are inserted, I noticed that the 95s rank was not getting updated. This one line will fix tbat I believe and the rank will be kept updated. It is entirely possible that I may not have understood the problem or solution correctly. In that case, please pardon my action to propose a change.

Here is an example run with only 10 numbers being inserted.

Tracking number 9
Tracking number 7
 d is 7, data is 9, left_size is 0.
Tracking number 7
 d is 7, data is 9, left_size is 1.
 d is 7, data is 7, left_size is 0.
Tracking number 10
 d is 10, data is 9, left_size is 2.
Tracking number 4
 d is 4, data is 9, left_size is 2.
 d is 4, data is 7, left_size is 1.
 d is 4, data is 7, left_size is 0.
Tracking number 5
 d is 5, data is 9, left_size is 3.
 d is 5, data is 7, left_size is 2.
 d is 5, data is 7, left_size is 1.
 d is 5, data is 4, left_size is 0.
Tracking number 4
 d is 4, data is 9, left_size is 4.
 d is 4, data is 7, left_size is 3.
 d is 4, data is 7, left_size is 2.
 d is 4, data is 4, left_size is 0.
Tracking number 10
 d is 10, data is 9, left_size is 5.
 d is 10, data is 10, left_size is 0.
Tracking number 7
 d is 7, data is 9, left_size is 5.
 d is 7, data is 7, left_size is 4.
 d is 7, data is 7, left_size is 3.
 d is 7, data is 4, left_size is 1.
 d is 7, data is 5, left_size is 0.
Tracking number 3
 d is 3, data is 9, left_size is 6.
 d is 3, data is 7, left_size is 5.
 d is 3, data is 7, left_size is 4.
 d is 3, data is 4, left_size is 1.
 d is 3, data is 4, left_size is 0.
printing tree...
data is 9left_size is 7
left-tree
data is 7left_size is 6
left-tree
data is 7left_size is 5
left-tree
data is 4left_size is 2
left-tree
data is 4left_size is 1
left-tree
data is 3left_size is 0
right-tree
data is 5left_size is 0
right-tree
data is 7left_size is 0
right-tree
data is 10left_size is 1
left-tree
data is 10left_size is 0
0 has rank -1
1 has rank -1
2 has rank -1
3 has rank 0
4 has rank 2
5 has rank 3
6 has rank -1
7 has rank 6
8 has rank -1
9 has rank 7
printing tree...second time
data is 9left_size is 7
left-tree
data is 7left_size is 6
left-tree
data is 7left_size is 5
left-tree
data is 4left_size is 2
left-tree
data is 4left_size is 1
left-tree
data is 3left_size is 0
right-tree
data is 5left_size is 0
right-tree
data is 7left_size is 0
right-tree
data is 10left_size is 1
left-tree
data is 10left_size is 0

However, it might just be that if that higher node is not visited one more time. I am testing further to make sure that is an issue.