学习周记
文章平均质量分 55
MidnightDJ
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
Leetcode代码学习周记——Two Sum
原题目链接: https://leetcode.com/problems/two-sum/description/ 题目描述: 给定一个整数数组,返回两个数字的索引,使它们相加得到一个特定的目标值。 你可以假设每个输入都只有一个解决方案,而您可能不会使用相同的元素两次。 实例: Given nums = [2, 7, 11, 15], target = 9, Because nu原创 2017-09-10 21:17:46 · 361 阅读 · 0 评论 -
Leetcode代码学习周记——Longest Substring Without Repeating Characters
原题目链接: https://leetcode.com/problems/longest-substring-without-repeating-characters/description/ 题目描述: 给定一个字符串,求其最长的没有重复字符的子字符串长度。 实例: 给定 "abcabcbb", 答案为 "abc", 长度为3。 给定 "bbbbb",答案为 "b原创 2017-09-21 10:36:18 · 294 阅读 · 0 评论 -
Leetcode代码学习周记——Reverse Integer
原题目链接: https://leetcode.com/problems/reverse-integer/description/ 题目描述: 反转一个整数的数位。 实例: x = 123,return 321 x = -123,return -321 注意: 输入假定为32位有符号整数。当反转的整数溢出时,您的函数应返回0。 除了题目给出的限制,还应该原创 2017-10-03 21:42:19 · 300 阅读 · 0 评论 -
Leetcode代码学习周记——Container With Most Water
题目链接: https://leetcode.com/problems/container-with-most-water/description/ 题目描述: Given n non-negative integers a1, a2, ..., an, where each represents a point at coordinate (i, ai). n vertical原创 2017-10-15 14:32:45 · 251 阅读 · 0 评论 -
Leetcode代码学习周记——Hamming Distance
题目链接: https://leetcode.com/problems/hamming-distance/description/ 题目描述: The Hamming distance between two integers is the number of positions at which the corresponding bits are different.原创 2017-12-10 21:49:41 · 279 阅读 · 0 评论 -
Leetcode代码学习周记——Judge Route Circle
题目链接: https://leetcode.com/problems/judge-route-circle/description/ 题目描述: Initially, there is a Robot at position (0, 0). Given a sequence of its moves, judge if this robot makes a circle, wh原创 2017-12-10 22:11:10 · 237 阅读 · 0 评论 -
Leetcode代码学习周记——Sqrt(x)
题目链接: https://leetcode.com/problems/sqrtx/description/ 题目描述: Implement int sqrt(int x). Compute and return the square root of x. x is guaranteed to be a non-negative integer. 实现函数原创 2017-12-11 20:35:18 · 332 阅读 · 0 评论 -
Leetcode代码学习周记——Self Dividing Numbers
题目链接: https://leetcode.com/problems/self-dividing-numbers/description/ 题目描述: A self-dividing number is a number that is divisible by every digit it contains. For example, 128 is a self-div原创 2017-12-16 15:35:48 · 302 阅读 · 0 评论 -
Leetcode代码学习周记——Longest Palindromic Substring
题目链接:https://leetcode.com/problems/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. 给定一个字原创 2018-01-13 21:48:52 · 230 阅读 · 0 评论 -
Leetcode代码学习周记——Palindrome Number
题目链接: https://leetcode.com/problems/palindrome-number/description/ 题目描述: Determine whether an integer is a palindrome. Do this without extra space. 判断一个整数是否为回文整数。 题解: 先排除复数和非0的10的倍数。 随后从该整数原创 2018-01-20 16:20:48 · 236 阅读 · 0 评论 -
Leetcode代码学习周记——Longest Common Prefix
题目链接: https://leetcode.com/problems/longest-common-prefix/description/ 题目描述: Write a function to find the longest common prefix string amongst an array of strings. 编写一个函数以查找一个字符串数组中所有字符串的最长公共前原创 2018-01-20 17:14:28 · 298 阅读 · 0 评论 -
Leetcode代码学习周记——3Sum
题目链接: https://leetcode.com/problems/3sum/description/ 题目描述: 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 wh原创 2018-01-20 18:16:36 · 263 阅读 · 0 评论 -
Leetcode代码学习周记——Find Anagram Mappings
题目链接: https://leetcode.com/problems/find-anagram-mappings/description/ 题目描述: Given two lists Aand B, and B is an anagram of A. B is an anagram of A means B is made by randomizing the or原创 2018-01-20 19:07:48 · 312 阅读 · 0 评论 -
Leetcode代码学习周记——Merge Two Binary Trees
题目链接: https://leetcode.com/problems/merge-two-binary-trees/description/ 题目描述: Given two binary trees and imagine that when you put one of them to cover the other, some nodes of the two trees原创 2018-01-20 19:18:40 · 269 阅读 · 0 评论 -
Leetcode代码学习周记——Number Complement
题目链接: https://leetcode.com/problems/number-complement/description/ 题目描述: Given a positive integer, output its complement number. The complement strategy is to flip the bits of its binary repres原创 2018-01-20 19:30:02 · 298 阅读 · 0 评论
分享