Minimize sum of an Array by swapping a Subarray with another Array
Given two arrays A[] and B[] each of size N, the task is to minimize the sum of an array by swapping a subarray. Examples: Input: A[] = {10, 30, 10, 60, 20}, B[] = {40, 10, 40, 30, 10}Output: 90Explanation: Swap the subarray {30, 10} with {60, 20}.The sum of array A[] = 10+30+10+30+10 = 90.The sum o