Skip to main content

Upper Bound

Learn Upper Bound (Searching, Data Structures & Algorithms) with worked examples, diagrams and interview questions. Free on JavaSchoolLab.

What is Upper Bound? The upper bound of a target is the index of the FIRST element that is STRICTLY greater than target - one position past the last occurrence of target, if it exists. Only one comparison changes from lower bound: &le; instead of < .

More lessons in Searching