Divide an array into two sub arrays such that their sums are equal and possibly maximum
The problem is NP-hard, by a straightforward reduction from the partition problem.  Therefore, you should not expect any efficient algorithm.  However, there is a pseudo-polynomial-time algorithm using dynamic programming (see pseudo-polynomial-time algorithm for the partition problem for inspiration).