At each node, you're partitioning values into lower half (left) and upper half (right).
The count of elements going left tells us: are the first smallest values all in the left subtree? - If yes (): recurse left with same - If no (): recurse right with You're doing binary search on the value space, guided by position counts.
Each level eliminates half the values. After levels, you reach a leaf containing the answer.