码迷,mamicode.com
首页 >  
搜索关键字:two points    ( 13225个结果
leetcode1143 Longest Common Subsequence
1 """ 2 Given two strings text1 and text2, return the length of their longest common subsequence. 3 A subsequence of a string is a new string generate ...
分类:其他好文   时间:2020-02-12 00:23:03    阅读次数:70
LeetCode | 0167: Two Sum II - Input array is sorted【Python】
LeetCode 0167: Two Sum II Input array is sorted【Python】 题目 "英文题目链接" Given an array of integers that is already sorted in ascending order\ , find two n ...
分类:编程语言   时间:2020-02-12 00:19:27    阅读次数:74
175. Combine Two Tables
Table: Person + + + | Column Name | Type | + + + | PersonId | int | | FirstName | varchar | | LastName | varchar | + + + PersonId is the primary key c ...
分类:其他好文   时间:2020-02-11 17:41:53    阅读次数:68
[LC] 1007. Minimum Domino Rotations For Equal Row
In a row of dominoes, A[i] and B[i] represent the top and bottom halves of the i-th domino. (A domino is a tile with two numbers from 1 to 6 - one on ...
分类:其他好文   时间:2020-02-11 11:48:25    阅读次数:101
刷题--双指针(2)
Two Sum类 首先是基本的Two Sum题解 用hashmap 时间复杂度O(n),空间复杂度O(n),每一次首先找hashmap中有没有target - nums[i], 如果没有将nums[i]入map 用双指针法,时间复杂度O(n + nlogn), 空间复杂度O(1) 首先要对数组进行排 ...
分类:其他好文   时间:2020-02-11 09:28:14    阅读次数:43
[Unit Testing] Jasmine Spies
it ('should add two numbers', () => { const logger = jasmine.createSpyObj('LoggerService', ['log']) // logger.log.and.returnValue(); const calculator ...
分类:其他好文   时间:2020-02-10 09:52:34    阅读次数:50
LeetCode167. Two Sum II - Input array is sorted(双指针)
题意:对于一个有序数组,输出和为target的两个元素的下标。题目保证仅有唯一解。 分析: 法一:二分。枚举第一个元素,二分找另一个元素,时间复杂度O(nlogn),非最优解。 class Solution { public: vector<int> twoSum(vector<int>& numb ...
分类:其他好文   时间:2020-02-09 22:14:01    阅读次数:73
LeetCode 1347. Minimum Number of Steps to Make Two Strings Anagram
"题目" 用hash,比较两个字符串数组的每个字符的hash值 ...
分类:其他好文   时间:2020-02-09 20:36:37    阅读次数:64
【leetcode】1346. Check If N and Its Double Exist
题目如下: Given an array arr of integers, check if there exists two integers N and M such that N is the double of M ( i.e. N = 2 * M). More formally check ...
分类:其他好文   时间:2020-02-09 18:55:33    阅读次数:79
【leetcode】1347. Minimum Number of Steps to Make Two Strings Anagram
题目如下: Given two equal-size strings s and t. In one step you can choose any character of t and replace it with another character. Return the minimum nu ...
分类:其他好文   时间:2020-02-09 18:39:10    阅读次数:68
13225条   上一页 1 ... 58 59 60 61 62 ... 1323 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!