Given an integer array nums and two integers firstLen and secondLen, return the maximum sum of elements in firstLen and secondLen.
The subarrays must be contiguous segments of the array that do not intersect. The subarray of length firstLen may occur before or after the subarray of length secondLen.
Constraints:
firstLen, secondLen
firstLen secondLen
firstLen secondLen nums.length
nums[i]
Given an integer array nums and two integers firstLen and secondLen, return the maximum sum of elements in firstLen and secondLen.
The subarrays must be contiguous segments of the array that do not intersect. The subarray of length firstLen may occur before or after the subarray of length secondLen.
Constraints:
firstLen, secondLen
firstLen secondLen
firstLen secondLen nums.length
nums[i]