Create boolean array of size high - low + 1 , each index i representing wether ( i + low ) th element found or not .
boolean [ ] points_of_range = new boolean [ high - low + 1 ] ; for ( int i = 0 ; i < arr . length ; i ++ ) {