The public rank is one-based, whereas Findusesa zero-based index:
function Select(i; var a; N): T
require 1 <= i <= N
return Find(i-1,a,0,N)
Thus rank i is index i−1. The boundary ranks return the minimum and maximum, and repeated values occupy as many ranks as their multiplicities in the multiset.