a nice, straightforward way to generate combinations using a mask vector with next_permutation