permutations -- returns all permutations of the entries of a list |
Syntax |
permutations(L: LIST): LIST |
Description |
Example |
/**/ permutations(3..5); [[3, 4, 5], [3, 5, 4], [4, 3, 5], [4, 5, 3], [5, 3, 4], [5, 4, 3]] /**/ permutations([2, 2, 5]); [[2, 2, 5], [2, 5, 2], [2, 2, 5], [2, 5, 2], [5, 2, 2], [5, 2, 2]] /**/ MakeSet(permutations([2, 2, 5])); [[2, 2, 5], [2, 5, 2], [5, 2, 2]] |
See Also |