
leetcode题解
文章平均质量分 71
sscssz
这个作者很懒,什么都没留下…
展开
-
【E】【51】【leetcode题解】Rectangle Area
Find the total area covered by two rectilinear rectangles in a 2D plane.Each rectangle is defined by its bottom left corner and top right corner as shown in the figure.Assume that the tota原创 2015-12-10 00:16:39 · 309 阅读 · 0 评论 -
【100题纪念】【有趣的算法】【leetcode题解】【E】【84】Merge Sorted Array
Given two sorted integer arrays nums1 and nums2, merge nums2 into nums1 as one sorted array.Note:You may assume that nums1 has enough space (size that is greater or equal to m + n) to hold addit原创 2015-12-14 18:24:33 · 766 阅读 · 0 评论 -
【VIP】342. Power of Four 【E】【leetcode】
Given an integer (signed 32 bits), write a function to check whether it is a power of 4.Example:Given num = 16, return true. Given num = 5, return false.Follow up: Could you solve it without原创 2016-04-19 14:49:47 · 386 阅读 · 0 评论 -
【leetcode】398. Random Pick Index【M】
Given an array of integers with possible duplicates, randomly output the index of a given target number. You can assume that the given target number must exist in the array.Note:The array size c原创 2016-09-13 09:52:02 · 1327 阅读 · 0 评论 -
【leetcode】438. Find All Anagrams in a String【E】
Given a string s and a non-empty string p, find all the start indices of p's anagrams in s.Strings consists of lowercase English letters only and the length of both strings s and p will not be lar原创 2016-10-27 10:53:41 · 1333 阅读 · 0 评论 -
【leetcode】423. Reconstruct Original Digits from English【M】【95】
Given a non-empty string containing an out-of-order English representation of digits 0-9, output the digits in ascending order.Note:Input contains only lowercase English letters.Input is g原创 2016-10-28 14:29:41 · 510 阅读 · 0 评论