Function iterator_split

Source
pub fn iterator_split<I>(
    it: I,
    max: usize,
) -> (impl Iterator<Item = I::Item>, impl Iterator<Item = I::Item>)
where I: Iterator + Clone,
Expand description

Given an iterator that’s cloneable, split it into two iterators at a given maximum number of elements.