Good Time to All, Amici.
i got following math problem: to split up number array into two subsets (S1, S2) where X[t] & Y[t] are multiplications of numbers of S1 & S2 respectively, t is index of iteration with condition: |X(0)-Y(0)|==MIN(0), |MIN(0)-(X(1)-Y(1))|==MIN(1), ..., |MIN(n-1)-(X(n)-Y(n))|==MIN(n). for example, let's take an array: 2, 5, 7 then: first pair is {2, 5}, {7} ==> X(0)==2*5==10, Y(0)==7, MIN(0)==3; second is {2, 7}, {5} ==> X(0)==14, Y(0)==5, MIN(1)==6; third is ..
------------------------------------------------
Thanks a lot in Advance.