Skip to main content

leapfrog_intersection

Function leapfrog_intersection 

Source
pub fn leapfrog_intersection(indexes: &[&Index]) -> Index
Expand description

Leapfrog intersection: labels present in ALL input indexes.

Classic leapfrog algorithm on sorted iterators. For each position, advance the smallest iterator to seek the maximum. When all iterators agree, emit the label.