![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
双指针
文章平均质量分 84
sscssz
这个作者很懒,什么都没留下…
展开
-
【VIP】【链表翻转】234. Palindrome Linked List【E】【94】
Given a singly linked list, determine if it is a palindrome.Follow up:Could you do it in O(n) time and O(1) space?Subscribe to see which companies asked this question原创 2016-04-05 10:43:31 · 405 阅读 · 0 评论 -
28. Implement strStr()【E】【59】
Implement strStr().Returns the index of the first occurrence of needle in haystack, or -1 if needle is not part of haystack.Subscribe to see which companies asked this question原创 2016-04-06 17:57:27 · 334 阅读 · 0 评论 -
209. Minimum Size Subarray Sum 【M】【35】
Given an array of n positive integers and a positive integer s, find the minimal length of a subarray of which the sum ≥ s. If there isn't one, return 0 instead.For example, given the array [2,3原创 2016-05-11 21:12:46 · 742 阅读 · 0 评论 -
15. 3Sum【M】【28】
Given an array S of n integers, are there elements a, b, c in S such that a + b + c = 0? Find all unique triplets in the array which gives the sum of zero.Note:Elements in a triplet (a,b,c原创 2016-05-31 14:25:05 · 475 阅读 · 0 评论 -
16. 3Sum Closest【M】【14】
Given an array S of n integers, find three integers in S such that the sum is closest to a given number, target. Return the sum of the three integers. You may assume that each input would have exact原创 2016-05-31 15:56:50 · 383 阅读 · 0 评论 -
【leetcode】167. Two Sum II - Input array is sorted【M】【100%】
Given an array of integers that is already sorted in ascending order, find two numbers such that they add up to a specific target number.The function twoSum should return indices of the two number原创 2016-09-06 23:18:17 · 481 阅读 · 5 评论