码迷,mamicode.com
首页 >  
搜索关键字:lc    ( 989个结果
LC 955. Delete Columns to Make Sorted II
We are given an array A of N lowercase letter strings, all of the same length. Now, we may choose any set of deletion indices, and for each string, we ...
分类:其他好文   时间:2019-02-04 18:09:31    阅读次数:202
LC 981. Time Based Key-Value Store
Create a timebased key-value store class TimeMap, that supports two operations. 1. set(string key, string value, int timestamp) Stores the key and val ...
分类:其他好文   时间:2019-02-04 16:47:53    阅读次数:156
LC 986. Interval List Intersections
Given two lists of closed intervals, each list of intervals is pairwise disjoint and in sorted order. Return the intersection of these two interval li ...
分类:其他好文   时间:2019-02-03 15:37:00    阅读次数:145
LC 988. Smallest String Starting From Leaf
Given the root of a binary tree, each node has a value from 0 to 25 representing the letters 'a' to 'z': a value of 0 represents 'a', a value of 1repr ...
分类:其他好文   时间:2019-02-03 14:11:35    阅读次数:195
LC 985. Sum of Even Numbers After Queries
We have an array A of integers, and an array queries of queries. For the i-th query val = queries[i][0], index = queries[i][1], we add val to A[index] ...
分类:其他好文   时间:2019-02-03 14:05:23    阅读次数:179
LC-375 猜数字大小Ⅱ
问题: 给出数字n,在1~n中,假设设定了一个数字x让你猜,你猜一个y,如果错误,那就收取¥y的费用,并告诉你x与y的大小关系。求出在1~n中,在最佳策略下猜出一个x至少要花费多少。(考虑所有情况) 思路: 这里用到了DP问题的解决思想。通过遍历猜所有数字的情况,例如n为5,猜3,那么就将问题分成, ...
分类:其他好文   时间:2019-01-28 21:15:31    阅读次数:163
LC-601 体育馆人流量
问题: 用sql语言查询连续三天人流量超过100的体育馆的信息 思路: sql语言不是很熟练,这里的方法也很暴力,就是将大于100人流量的体育馆记录全部做连接,然后筛选出id相邻3个的。。 代码: ...
分类:其他好文   时间:2019-01-28 00:40:01    阅读次数:195
LC-593 验证正方形
问题: 给出4个点,判断这四个点能否构成一个正方形 思路: 一个正方形意味着4条边相等,四个角都为直角。我就简单地先计算p1到p2,p3,p4的三个向量,然后判断向量v2,v3,v4之间,有哪两个向量是垂直的(点积等于0)。 找出2个垂直向量之后(例如v2,v3),就判断这两个向量的长度是否相等,而 ...
分类:其他好文   时间:2019-01-24 14:29:14    阅读次数:125
航天独角兽Spacex
2018年2月7日下午3时45分,猎鹰重型火箭在位于卡纳维拉尔角的肯尼迪航天中心LC-39A平台顺利升空。火箭直升云霄,按照既定轨道持续升空,位于美国弗罗里达州卡纳维拉尔角的航天发射中心硝烟四起,非常壮观。火箭上搭载着SpaceX公司旗下的一辆特斯拉红色敞篷跑车Roadster升空。车座上还放置着一 ...
分类:其他好文   时间:2019-01-23 18:41:48    阅读次数:415
LC 980. Unique Paths III
On a 2-dimensional grid, there are 4 types of squares: 1 represents the starting square. There is exactly one starting square. 2 represents the ending ...
分类:其他好文   时间:2019-01-23 01:33:49    阅读次数:227
989条   上一页 1 ... 34 35 36 37 38 ... 99 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!