/guava/guava/src/com/google/common/collect/MinMaxPriorityQueue.java
int limit = Math.min( index, len - size) + len;
int limit = Math.min ( index, size - len ) + len;
} int findMin(int index, int len) { if (index >= size) { return -1; } checkState(index > 0); <extra_id_0> int minIndex = index; for (int i = index + 1; i < limit; i++) { if (compareElements(i, minIndex) < 0) { minIndex = i; } }