Skip to content

Commit 8dc850c

Browse files
author
lucifer
committed
2 parents 7243c00 + 288a0d7 commit 8dc850c

File tree

175 files changed

+2155
-541
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

175 files changed

+2155
-541
lines changed

Kapture 2020-08-19 at 11.37.36.gif

23.6 MB
Loading

LICENSE.txt

Lines changed: 100 additions & 201 deletions
Large diffs are not rendered by default.

README.en.md

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -99,15 +99,13 @@ The data structures mainly include:
9999
#### Easy (Translation in Progress)
100100

101101
- [0001.TwoSum](./problems/1.two-sum.en.md)🆕
102-
103102
- [0053.maximum-sum-subarray](./problems/53.maximum-sum-subarray-en.md) 🆕
104-
105103
- [0198.house-robber](./problems/198.house-robber.en.md)🆕
104+
- [0501.find-mode-in-binary-search-tree](./problems/501.Find-Mode-in-Binary-Search-Tree-en.md)🆕
106105

107106
#### Medium (Translation in Progress)
108107

109108
- [0002. Add Two Numbers](./problems/2.add-two-numbers.en.md)
110-
111109
- [0078.subsets](./problems/78.subsets-en.md)
112110
- [0079.word-search](./problems/79.word-search-en.md)
113111
- [0086.partition-list](./problems/86.partition-list.md)

README.md

Lines changed: 22 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -31,22 +31,13 @@
3131

3232
![](https://tva1.sinaimg.cn/large/007S8ZIlly1ghluemaoj3j30z90dtmy5.jpg)
3333

34-
## 非科学人士看过来
35-
36-
如果是国内的非科学用户,可以使用 https://lucifer.ren/leetcode ,整站做了静态化,速度贼快!但是阅读体验可能一般,大家也可以访问[力扣加加](http://leetcode-solution.cn/)(暂时没有静态化)获得更好的阅读体验。
34+
## 项目预览
3735

38-
## 怎么刷 LeetCode?
36+
![project-overview](https://github.com/azl397985856/leetcode/blob/master/Kapture%202020-08-19%20at%2011.37.36.gif)
3937

40-
- [我是如何刷 LeetCode 的](https://www.zhihu.com/question/280279208/answer/824585814)
41-
- [算法小白如何高效、快速刷 leetcode?](https://www.zhihu.com/question/321738058/answer/1279464192)
38+
可以清晰地看出仓库组织关系。
4239

43-
## 刷题插件(开发中)
44-
45-
- [刷题效率低?或许你就差这么一个插件](https://lucifer.ren/blog/2020/06/06/algo-chrome-extension/)
46-
47-
## 91 天学算法
48-
49-
- [91 天,遇见不一样的自己](https://lucifer.ren/blog/2020/05/23/91-algo/)
40+
(你可以下载本仓库 和 obsidian 软件,然后用 obsidian 打开获得更好的阅读效果)
5041

5142
## 介绍
5243

@@ -66,6 +57,23 @@ leetcode 题解,记录自己的 leetcode 解题之路。
6657

6758
> 只有熟练掌握基础的数据结构与算法,才能对复杂问题迎刃有余。
6859
60+
## 非科学人士看过来
61+
62+
如果是国内的非科学用户,可以使用 https://lucifer.ren/leetcode ,整站做了静态化,速度贼快!但是阅读体验可能一般,大家也可以访问[力扣加加](http://leetcode-solution.cn/)(暂时没有静态化)获得更好的阅读体验。
63+
64+
## 怎么刷 LeetCode?
65+
66+
- [我是如何刷 LeetCode 的](https://www.zhihu.com/question/280279208/answer/824585814)
67+
- [算法小白如何高效、快速刷 leetcode?](https://www.zhihu.com/question/321738058/answer/1279464192)
68+
69+
## 刷题插件(开发中)
70+
71+
- [刷题效率低?或许你就差这么一个插件](https://lucifer.ren/blog/2020/06/06/algo-chrome-extension/)
72+
73+
## 91 天学算法
74+
75+
- [91 天,遇见不一样的自己](https://lucifer.ren/blog/2020/05/23/91-algo/)
76+
6977
## 关于我
7078

7179
擅长前端工程化,前端性能优化,前端标准化等,做过。net, 搞过 Java,现在是一名前端工程师,我的个人博客:https://lucifer.ren/blog/
@@ -253,4 +261,4 @@ anki - 文件 - 导入 - 下拉格式选择“打包的 anki 集合”,然后
253261

254262
## License
255263

256-
[Apache-2.0](./LICENSE.txt)
264+
[CC BY-NC-ND 4.0](./LICENSE.txt)

problems/1.two-sum.md

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,21 @@ https://leetcode-cn.com/problems/two-sum
2323

2424
## 公司
2525

26-
- 字节、百度、腾讯
26+
- 字节
27+
- 百度
28+
- 腾讯
29+
- adobe
30+
- airbnb
31+
- amazon
32+
- apple
33+
- bloomberg
34+
- dropbox
35+
- facebook
36+
- linkedin
37+
- microsoft
38+
- uber
39+
- yahoo
40+
- yelp
2741

2842
## 思路
2943

@@ -59,5 +73,12 @@ const twoSum = function (nums, target) {
5973

6074
**复杂度分析**
6175

62-
- 时间复杂度:O(N)
63-
- 空间复杂度:O(N)
76+
- 时间复杂度:$O(N)$
77+
- 空间复杂度:$O(N)$
78+
79+
更多题解可以访问我的LeetCode题解仓库:https://github.com/azl397985856/leetcode 。 目前已经35K star啦。
80+
81+
关注公众号力扣加加,努力用清晰直白的语言还原解题思路,并且有大量图解,手把手教你识别套路,高效刷题。
82+
83+
84+
![](https://tva1.sinaimg.cn/large/007S8ZIlly1gfcuzagjalj30p00dwabs.jpg)

problems/101.symmetric-tree.md

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,10 +33,21 @@ https://leetcode-cn.com/problems/symmetric-tree/
3333
3434
3535
```
36+
37+
## 公司
38+
39+
- 阿里
40+
- 腾讯
41+
- 百度
42+
- 字节
43+
- bloomberg
44+
- linkedin
45+
- microsoft
46+
3647
## 前置知识
3748

38-
- 二叉树
39-
- 递归
49+
- [二叉树](https://github.com/azl397985856/leetcode/blob/master/thinkings/basic-data-structure.md)
50+
- [递归](https://github.com/azl397985856/leetcode/blob/master/thinkings/dynamic-programming.md)
4051

4152
## 思路
4253

@@ -103,7 +114,7 @@ class Solution:
103114
return dfs(root.left, root.right)
104115
```
105116

106-
**_复杂度分析_**
117+
**复杂度分析**
107118

108119
- 时间复杂度:$O(N)$,其中 N 为节点数。
109120
- 空间复杂度:递归的深度最高为节点数,因此空间复杂度是 $O(N)$,其中 N 为节点数。

problems/1011.capacity-to-ship-packages-within-d-days-cn.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,10 @@ https://leetcode-cn.com/problems/capacity-to-ship-packages-within-d-days
5151

5252
- 二分法
5353

54+
## 公司
55+
56+
- 阿里
57+
5458
## 思路
5559

5660
这道题和[猴子吃香蕉](https://github.com/azl397985856/leetcode/blob/master/problems/875.koko-eating-bananas.md) 简直一摸一样,没有看过的建议看一下那道题。

problems/1014.best-sightseeing-pair.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,11 @@ https://leetcode-cn.com/problems/best-sightseeing-pair/description/
2525

2626
- 动态规划
2727

28+
## 公司
29+
30+
- 阿里
31+
- 字节
32+
2833
## 思路
2934

3035
最简单的思路就是两两组合,找出最大的,妥妥超时,我们来看下代码:

problems/1015.smallest-integer-divisible-by-k.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,12 @@ https://leetcode-cn.com/problems/smallest-integer-divisible-by-k/description/
3636

3737
## 前置知识
3838

39+
- 循环节
40+
41+
## 公司
42+
43+
- 暂无
44+
3945
## 思路
4046

4147
这道题是说给定一个 K 值,能否找到一个形如 1,11,111,1111 。。。 这样的数字 n 使得 n % K == 0。

problems/1019.next-greater-node-in-linked-list.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,11 @@ https://leetcode-cn.com/problems/next-greater-node-in-linked-list/submissions/
4040
- 链表
4141
-
4242

43+
## 公司
44+
45+
- 腾讯
46+
- 字节
47+
4348
## 思路
4449

4550
看完题目就应该想到单调栈才行,LeetCode 上关于单调栈的题目还不少,难度都不小。但是一旦你掌握了这个算法,那么这些题目对你来说都不是问题了。

0 commit comments

Comments
 (0)