solution to subsets