What is the best way to determine "the rest of the sequence" generated with the subset() method?
For example to get exactly 3 partitions out of 5 elements and filling the second partition again with a "subset of the rest" and filling last partition with the subset of elements not used in the first 2 partitions?
What is the best way to determine "the rest of the sequence" generated with the
subset()
method? For example to get exactly3
partitions out of5
elements and filling the second partition again with a "subset of the rest" and filling last partition with the subset of elements not used in the first 2 partitions?How to improve this snippet?