Function lattices::test::cartesian_power
source · pub fn cartesian_power<T, const N: usize>(
items: &[T]
) -> impl ExactSizeIterator<Item = [&T; N]> + Clone
Expand description
Returns an iterator of N
-length arrays containing all possible permutations (with
replacement) of items in items
. I.e. the N
th cartesian power of items
. I.e. the cartesian
product of items
with itself N
times.