Searching
Algorithms that find items, positions, or answers in a collection.
Searching algorithms locate values or boundaries in data, from simple scans to methods that rely on sorted structure.
Linear Search
Finds a target by checking items one by one until a match is found or the input ends.
Binary Search
Finds a target or insertion point in sorted data by repeatedly halving the candidate range.
Interpolation Search
Searches sorted numeric data by estimating where the target should be.
Binary Search on Answer
Finds an optimal numeric answer by binary searching a monotone feasibility predicate.
Exponential Search
Finds a search range by doubling the bound, then uses binary search inside it.
Fibonacci Search
Searches sorted data using Fibonacci-sized partitions.
Hash Lookup
Finds values by hashing keys directly to likely storage locations.
Jump Search
Searches sorted data by jumping ahead in blocks before scanning a small block.
Quickselect
Finds the kth smallest item by partitioning around pivots without fully sorting.
Ternary Search
Finds an optimum in a unimodal range by comparing two interior points.
Lower Bound
Finds the first sorted position where a value could be inserted without breaking order.
Median of Medians
Selects a pivot that guarantees linear-time selection in the worst case.
Uniform Binary Search
Uniform Binary Search uses ordering or monotonic structure to eliminate candidates.
Galloping Search
Galloping Search locates items by exploiting structure in the collection or search space.
Rotated Array Search
Rotated Array Search uses ordering or monotonic structure to eliminate candidates.
Peak Finding
Peak Finding uses ordering or monotonic structure to eliminate candidates.
Saddleback Search
Saddleback Search locates items by exploiting structure in the collection or search space.
Fractional Cascading
Fractional Cascading locates items by exploiting structure in the collection or search space.
KD-Tree Nearest Neighbor Search
KD-Tree Nearest Neighbor Search finds nearby points while pruning distant candidates.
Ball Tree Search
Ball Tree Search locates items by exploiting structure in the collection or search space.
Vantage-Point Tree Search
Vantage-Point Tree Search locates items by exploiting structure in the collection or search space.
Branch and Bound Nearest Neighbor
Branch and Bound Nearest Neighbor finds nearby points while pruning distant candidates.
Bloom Filter Membership Query
Bloom Filter Membership Query locates items by exploiting structure in the collection or search space.
Binary Search in Answer Space
Binary Search in Answer Space uses ordering or monotonic structure to eliminate candidates.
Floyd-Rivest Selection
Selects the kth order statistic by sampling to narrow the partition range.