You are not logged in.
Pages: 1
Howdy,
I'm trying to solve this problem, but can't seem to make much progress.
Given a set of positive numbers, divide it into 2 sets (which differ in size by 1, at max) so that the difference of their sums is minimum.
So, for e.g., given the following set: [8, 4, 25, 17], the possible combinations are:
1. [8,4] & [25,17] - 30
2. [8,25] & [4,17] - 12
3. [8,17] & [4,25] - 4
Clearly, the answer is 3: [4, 25] & [8, 17].
Thanks.
Pages: 1