View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Mac Mac is offline
external usenet poster
 
Posts: 213
Default 'Composing' numbers

Assume the following situation:

7 rows containing numbers like:
Row 1: 1,2,4,8
Row 2: 5,10
Row 3: 5,10
Row 4: 5,10
Row 5: 1,2,4,8
Row 6: 1,2,4,8
Row 7: 1,2,4,8

Then, from these numbers, one is picked per each row (e.g. into column E);
finally, cell E8 then gives an aggregate of the seven selected numbers. What
I want the code to accomplish is: if I need the aggregate to be 25, what are
all the possibilities (7 numbers) of picking one number from each row to add
up to this sum? And for aggregate of 30, 35, and so on? All ideas welcome!!!