
leetcode
NJU_CAIBANG
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
leetcode189 Rotate Array
leetcode 189 Given an array, rotate the array to the right by k steps, where k is non-negative. 方法一 开辟新数组,使用取余求下标的方法 class Solution { public void rotate(int[] nums, int k) { int[] temp=new...原创 2019-04-15 20:04:26 · 183 阅读 · 0 评论 -
leetcode217 Contains Duplicate
leetcode 217 Given an array of integers, find if the array contains any duplicates. Your function should return true if any value appears at least twice in the array, and it should return false if eve...原创 2019-04-15 20:44:04 · 179 阅读 · 0 评论 -
leetcode136 Single Number
Given a non-empty array of integers, every element appears twice except for one. Find that single one. Note: Your algorithm should have a linear runtime complexity. Could you implement it without usin...原创 2019-04-15 21:10:15 · 207 阅读 · 0 评论