Apr-26-2021, 12:56 PM
You might want to look at the
itertools
module to see if anything there is useful. I don't know from your description whether product
from that module is appropriate for you.