...

/

Split Array Into Two Arrays to Minimize Sum Difference

Split Array Into Two Arrays to Minimize Sum Difference

Try to solve the Split Array Into Two Arrays to Minimize Sum Difference problem.

Statement

You are given an integer array, nums, consisting of 2∗n2 * n elements.

Your task is to divide the array into two subarrays of length nn, such that each element in nums belongs to exactly one of the two subarrays, and the absolute difference between ...