摘要:
438.找到字符串中所有的字母异位词 思路:固定窗口 点击查看代码 class Solution { public List<Integer> findAnagrams(String s, String p) { List<Integer> result = new ArrayList<>(); i 阅读全文
摘要:
209. 长度最小的子数组 点击查看代码 class Solution { public int minSubArrayLen(int target, int[] nums) { int n = nums.length; int res = Integer.MAX_VALUE; int sum = 阅读全文
摘要:
盛最多水的容器 点击查看代码 class Solution { public int maxArea(int[] height) { int n = height.length; int l = 0; int r = n - 1; int res = Integer.MIN_VALUE; while 阅读全文