It's easy in python to calculate simple permutations using itertools.permutations().
You can even find some possible permutations of multiple lists.
import itertools
s=[ [ 'a', 'b', 'c'], ['d'], ['e', 'f'] ]
for l in list(itertools.product(*s)):
print(l)
('a', 'd', 'e')
('a', 'd', 'f')
('b', 'd', 'e')
('b', 'd', 'f')
('c', 'd', 'e')
('c', 'd', 'f')
It's also possible to find permutations of different lengths.
import itertools
s = [1, 2, 3]
for L in range(0, len(s)+1):
for subset in itertools.combinations(s, L):
print(subset)
()
(1,)
(2,)
(3,)
(1, 2)
(1, 3)
(2, 3)
(1, 2, 3)
How would you find permutations of all possible 1) lengths, 2) orders, and 3) from multiple lists?
I would assume the first step would be to combine the lists into one. A list will not de-dup items like a set would.
s=[ [ 'a', 'b', 'c'], ['d'], ['e', 'f'] ]
('a', 'b')
('a', 'c')
('a', 'd')
('a', 'e')
('a', 'f')
...
('b', 'a')
('c', 'a')
...
('a', 'b', 'c', 'd', 'e')
...
('a', 'b', 'c', 'd', 'e', 'f')
...
('f', 'a', 'b', 'c', 'd', 'e')