Split Array With Minimum Difference
Try each cut, keep only cuts whose left part strictly rises and right part strictly falls, and track the smallest gap between the two sums.
Try each cut, keep only cuts whose left part strictly rises and right part strictly falls, and track the smallest gap between the two sums.