This sounds like a common homework problem. Googling something like all possible combinations of numbers that add up to N gives tons of results.
In reply to Re: check possible combination of sum using given array
by haukex
in thread check possible combination of sum using given array
by dideod.yang
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |