Comparator understanding

why this code is not running for this compare function ,as it is the actual compare function for the lower bound function. and how the compare function is called again and again

please give a reply asap