public class Solution { /** * max sum of the subarray * @param arr int整型一维数组 the array * @return int整型 */ public int maxsumofSubarray (int[] arr) { for(int i=1;i<arr.length;i++){ arr[i]=arr[i]>(arr[i-1]+arr[i])?arr[i]:(arr[i-1]+arr[i]); } r...