core :: Collection :: permutations
r
-length permutations on self (all possible ordering) without repeated elements.See CartesianCollection
for details.
FIXME: Cannot be used if RTA is enabled. So niti
or --erasure
only.
# All `r`-length permutations on self (all possible ordering) without repeated elements.
#
# See `CartesianCollection` for details.
#
# FIXME: Cannot be used if RTA is enabled. So `niti` or `--erasure` only.
fun permutations(r: Int): Collection[SequenceRead[E]]
do
var res = new CombinationCollection[E](self, r)
res.are_sorted = false
res.are_unique = true
return res
end
lib/combinations/combinations.nit:36,2--47,4