How to generate permutations of n variables given the domain of each variable. (in python)
I know about itertools, but that requires a fixed domain for the permutations so that won't work. Also is there a python library that does this? Thanks.
Basically: Given 3 variables: A with Domain (2,3) B with Domain (1) C with Domain (1,2,3)
How do you generate all permutations of ABC?
2,1,1
3,1,1
2,1,2
3,1,2
2,1,3
3,1,3