Binary search algorithm

ID: binary-search-algorithm

Binary search is an efficient algorithm for finding a target value within a sorted array (or list). The core idea of binary search is to repeatedly divide the search interval in half, which significantly reduces the number of comparisons needed to find the target value compared to linear search methods. ### How Binary Search Works: 1. **Initial Setup**: Start with two pointers, `low` and `high`, which represent the boundaries of the search interval.

New to topics? Read the docs here!