Subset sum - Recover solution
问题 I have written a dynamic programming algorithm that finds the total amount of subsets that sum up to a target value. However, I am having trouble developing a function to recover the solution (that is, print out the actual subsets). For example, let's take the set [1,3,5,7,9,10] with the target 13 . My algorithm calculates that there are 3 subsets. The output table is shown in the image below. Because this is a simple set, I can manually determine which three subsets make up the target. That