Expand description
const fn combinations iter adapter
§Examples
use const_combinations::IterExt;
let mut combinations = (1..5).combinations();
assert_eq!(combinations.next(), Some([1, 2, 3]));
assert_eq!(combinations.next(), Some([1, 2, 4]));
assert_eq!(combinations.next(), Some([1, 3, 4]));
assert_eq!(combinations.next(), Some([2, 3, 4]));
assert_eq!(combinations.next(), None);
Structs§
- Combinations
- An iterator that returns k-length combinations of values from
iter
. - Permutations
- An iterator that returns k-length permutations of values from
iter
. - Slice
Combinations - An iterator that returns k-length combinations of values from
slice
. - Slice
Permutations - An iterator that returns k-length permutations of values from
slice
.