Help writing a math function
Posted: Mon Dec 18, 2006 4:34 pm
Hopefully someone can help me:
I need to write a function that can be passed a value1 and an array containing multiple numerical values.
the function then needs to be able to determine which values in the array when summed together equal the value1 passed to it.
so i guess the function could return the set of array values that could add up to value1, then return the next set, etc...
this isn't for school or anything, actually for work and would make my life a ton easier. does anyone have any ideas?
I need to write a function that can be passed a value1 and an array containing multiple numerical values.
the function then needs to be able to determine which values in the array when summed together equal the value1 passed to it.
so i guess the function could return the set of array values that could add up to value1, then return the next set, etc...
this isn't for school or anything, actually for work and would make my life a ton easier. does anyone have any ideas?