pub fn sample_single_excluding_iteration<'a, R, T, E>(
rng: &mut R,
slice: &'a [T],
excluded: E,
) -> Option<&'a T>Expand description
Linear-scan implementation of sample_single_excluding. Counts non-excluded
entries, then picks the k-th. Wins for very small slices (n <= 3) where
the per-trial overhead of rejection sampling exceeds the cost of a tiny
filter. Exposed so benchmarks can compare strategies directly.