I am trying to generate a list of all possible permutations that meet various sub-criteria. I can\'t do a brute force approach because memory usage would be an issue. Ideally I\