Skip to content

Commit

Permalink
micro fix
Browse files Browse the repository at this point in the history
  • Loading branch information
halfrost committed Sep 6, 2020
1 parent 5fa44b9 commit e02e370
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 2 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2119,7 +2119,7 @@ Problems List in [there](https://books.halfrost.com/leetcode/ChapterTwo/Sliding_
![](./topic/Segment_Tree.png)
- 线段数的经典数组实现写法。将合并两个节点 pushUp 逻辑抽象出来了,可以实现任意操作(常见的操作有:加法,取 max,min 等等)。第 218 题,第 303 题,第 307 题,第 699 题。
- 线段树的经典数组实现写法。将合并两个节点 pushUp 逻辑抽象出来了,可以实现任意操作(常见的操作有:加法,取 max,min 等等)。第 218 题,第 303 题,第 307 题,第 699 题。
- 计数线段树的经典写法。第 315 题,第 327 题,第 493 题。
- 线段树的树的实现写法。第 715 题,第 732 题。
- 区间懒惰更新。第 218 题,第 699 题。
Expand Down
24 changes: 24 additions & 0 deletions website/content/ChapterFour/pytool/CutContent.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
import os
import re
import glob

# file_name = 'Array.md'
reg = "## 题目大意"

current_working_dir = os.getcwd()
# print(f"current_working_dir: {current_working_dir}")

dir_names = glob.glob("*.md")
dir_names.sort()
print(len(dir_names))

for file_name in dir_names:
# print(file_name)
with open(file_name, "r") as myfile:
codeContent = myfile.read()
findIndex = codeContent.find(reg)
# print(findIndex)
content = codeContent[findIndex:]
with open(file_name, "w") as myfile:
myfile.write(content)
print("Finished")
2 changes: 1 addition & 1 deletion website/content/ChapterTwo/Segment_Tree.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ type: docs

![](https://img.halfrost.com/Leetcode/Segment_Tree.png)

- 线段数的经典数组实现写法。将合并两个节点 pushUp 逻辑抽象出来了,可以实现任意操作(常见的操作有:加法,取 max,min 等等)。第 218 题,第 303 题,第 307 题,第 699 题。
- 线段树的经典数组实现写法。将合并两个节点 pushUp 逻辑抽象出来了,可以实现任意操作(常见的操作有:加法,取 max,min 等等)。第 218 题,第 303 题,第 307 题,第 699 题。
- 计数线段树的经典写法。第 315 题,第 327 题,第 493 题。
- 线段树的树的实现写法。第 715 题,第 732 题。
- 区间懒惰更新。第 218 题,第 699 题。
Expand Down

0 comments on commit e02e370

Please sign in to comment.