![](https://img-blog.csdnimg.cn/20201014180756922.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
leetcode
Ostrich hunter
这个作者很懒,什么都没留下…
展开
-
LeetCode题集(5)
922. 按奇偶排序数组 II class Solution { public int[] sortArrayByParityII(int[] A) { int j = 1; for (int i = 0; i < A.length - 1; i = i + 2) { if ((A[i] & 1) != 0) {...原创 2020-03-30 13:59:02 · 91 阅读 · 0 评论 -
LeetCode题集(4)
1337. 方阵中战斗力最弱的 K 行 class Solution { public int[] kWeakestRows(int[][] mat, int k) { int[] re = new int[k]; int reIndex = 0; boolean[] flag = new boolean[mat.leng...原创 2020-03-23 13:03:45 · 75 阅读 · 0 评论 -
LeetCode题集(3)
1296. 划分数组为连续数字的集合 class Solution { public boolean isPossibleDivide(int[] nums, int k) { int len = nums.length; if(len % k != 0) return false; Map<Integer, Integer...原创 2020-03-15 20:15:36 · 70 阅读 · 0 评论 -
LeetCode题集(2)
442. 数组中重复的数据 class Solution { public List<Integer> findDuplicates(int[] nums) { List<Integer> ans = new ArrayList<Integer>(); int d = nums.length+1; ...原创 2020-03-01 13:59:05 · 76 阅读 · 0 评论 -
LeetCode题集(1)
数组简单编程题 1295. 统计位数为偶数的数字 class Solution1295 { public int findNumbers(int[] nums) { int count =0; for(int i=0;i<nums.length;i++){ if(String.valueOf(nums[i]).leng...原创 2020-02-23 14:26:23 · 81 阅读 · 0 评论