public class Solution { /** * * @param arr int整型一维数组 the array * @return int整型 */ public int maxLength (int[] arr) { // write code here if(arr.length==0) { return 0; } HashMap<Integer,Integer> map=new HashMap<>(); int left=0; int max=0; for(int i=0;i<arr.length;i++) { if(map.containsK...