Split Array Largest Sum
Given an integer array nums and an integer m, split the array into m non-empty continuous subarrays. Write an algorithm to minimize the largest sum among these m subarrays.
Split Array Largest Sum

Given an integer array nums and an integer m, split the array into m non-empty continuous subarrays. Write an algorithm to minimize the largest sum among these m subarrays.

Example 1:
Input: {"nums":[7,2,5,10,8],"m":2}
Output: 18
Input
arr ={"nums":[7,2,5,10,8],"m":2}

Start. Search range [max(nums), sum(nums)]

7

2

5

10

8

Low
10
Mid (k)

-

High
32

Result: 32

Variables
No variables to display
DepthFunction Call
Stack empty
0/11