permutator implemented as iterator