摘要: __author__ = 'zenglinwang' class Solution(object): def twoSum(self, nums, target): """ :type nums: List[int] :type target: int :rtype: List[int] """ ... 阅读全文
posted @ 2016-08-05 10:49 兔纸不吃草 阅读(125) 评论(0) 推荐(0)
摘要: #include #include /** * Definition for singly-linked list. * struct ListNode { * int val; * struct ListNode *next; * }; */ struct ListNode { int val; struct ListNode *next... 阅读全文
posted @ 2016-08-05 10:48 兔纸不吃草 阅读(136) 评论(0) 推荐(0)
摘要: #include // 5. Longest Palindromic Substring // Given a string S, find the longest palindromic substring in S. // You may assume that the maximum length of S is 1000, // and there exists one uniq... 阅读全文
posted @ 2016-08-05 10:46 兔纸不吃草 阅读(154) 评论(0) 推荐(0)
摘要: #include #include // 7. Reverse Integer // Difficulty: Easy // Reverse digits of an integer. // Example1: x = 123, return 321 // Example2: x = -123, return -321 // https://leetcode.com/problems/re... 阅读全文
posted @ 2016-08-05 10:45 兔纸不吃草 阅读(125) 评论(0) 推荐(0)
摘要: #include #include #include // 9. Palindrome Number // Determine whether an integer is a palindrome. Do this without extra space. // https://leetcode.com/problems/palindrome-number/ // Algorith... 阅读全文
posted @ 2016-08-05 10:43 兔纸不吃草 阅读(222) 评论(0) 推荐(0)