![](https://img-blog.csdnimg.cn/20201014180756757.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
Easy
Joyer_99
这个作者很懒,什么都没留下…
展开
-
459. Repeated Substring Pattern[Easy]
DescriptionGiven a non-empty string check if it can be constructed by taking a substring of it and appending multiple copies of the substring together. You may assume the given string consists of low...原创 2019-11-22 13:00:40 · 126 阅读 · 0 评论 -
448. Find All Numbers Disappeared in an Array[Easy]
DescriptionGiven an array of integers where 1 ≤ a[i] ≤ n (n = size of array), some elements appear twice and others appear once.Find all the elements of [1, n] inclusive that do not appear in this a...原创 2019-11-12 15:15:49 · 106 阅读 · 0 评论 -
【Leetcode】Power of N
在Leetcode上发现了三个很有趣的Power of N的题,分别是判断一个数是否是2、3、4的n次幂。在第一次刷题的时候,全部采用的都是将数字num转换为n进制,然后判断该进制是否为1个1加上x个0的形式,从而得到结果。在第二次刷题的时候,特别注意了Follow up: Could you do it without using any loop / recursion?,从而开始思考怎么...原创 2019-11-03 15:02:21 · 138 阅读 · 0 评论 -
【Leetcode】53. Maximum Subarray [Easy]
DescriptionGiven an integer array nums, find the contiguous subarray (containing at least one number) which has the largest sum and return its sum.ExampleInput: [-2,1,-3,4,-1,2,1,-5,4],Output: 6E...原创 2019-09-04 10:57:22 · 92 阅读 · 0 评论 -
【Leetcode】371. Sum of Two Integers [Easy]
DescriptionCalculate the sum of two integers a and b, but you are not allowed to use the operator + and -.ExampleExample 1:Input: a = 1, b = 2Output: 3Example 2:Input: a = -2, b = 3Output: 1...原创 2019-09-04 10:58:22 · 67 阅读 · 0 评论 -
【Leetcode】88. Merge Sorted Array[Easy]
DescriptionGiven two sorted integer arrays nums1 and nums2, merge nums2 into nums1 as one sorted array.Note:The number of elements initialized in nums1 and nums2 are m and n respectively.You may ...原创 2019-09-05 12:45:25 · 81 阅读 · 0 评论 -
【Leetcode】326. Power of Three[Easy]
DescriptionGiven an integer, write a function to determine if it is a power of three.ExampleExample 1:Input: 27Output: trueExample 2:Input: 45Output: falseSolvingConverting the input into ...原创 2019-09-05 13:18:31 · 87 阅读 · 0 评论 -
【Leetcode】160. Intersection of Two Linked Lists[Easy]
DescriptionWrite a program to find the node at which the intersection of two singly linked lists begins.For example, the following two linked lists:A: a1->a2->c1->c2->c3B: b1->b...原创 2019-09-07 00:16:07 · 78 阅读 · 0 评论