Add note
This commit is contained in:
parent
4ae4313646
commit
88ec5dc3d8
@ -2,12 +2,18 @@
|
|||||||
|
|
||||||
# 数组
|
# 数组
|
||||||
|
|
||||||
|
- [总结](./array.md)
|
||||||
- [二分查找](./bin_search.md)
|
- [二分查找](./bin_search.md)
|
||||||
- [移除元素](./remove_elements.md)
|
- [移除元素](./remove_elements.md)
|
||||||
- [长度最小的子数组](./minimum_size_subarray_sum.md)
|
- [长度最小的子数组](./minimum_size_subarray_sum.md)
|
||||||
|
|
||||||
|
# 链表
|
||||||
|
|
||||||
|
- [总结](./linked-list.md)
|
||||||
|
|
||||||
# 字符串
|
# 字符串
|
||||||
|
|
||||||
|
- [总结](./string.md)
|
||||||
- [替换空格](./substitute_spaces.md)
|
- [替换空格](./substitute_spaces.md)
|
||||||
- [翻转字符串里的单词](./reverse_words_in_a_string.md)
|
- [翻转字符串里的单词](./reverse_words_in_a_string.md)
|
||||||
- [左旋转字符串](./reverse_left_words.md)
|
- [左旋转字符串](./reverse_left_words.md)
|
||||||
|
7
notes/src/array.md
Normal file
7
notes/src/array.md
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
# 总结
|
||||||
|
|
||||||
|
搜索有序数组中的元素:二分法。
|
||||||
|
|
||||||
|
原地移除数组中的元素:双指针,快指针满足条件时覆盖到慢指针。
|
||||||
|
|
||||||
|
当需要处理“连续子数组”时,考虑滑动窗口。
|
1
notes/src/linked-list.md
Normal file
1
notes/src/linked-list.md
Normal file
@ -0,0 +1 @@
|
|||||||
|
# 总结
|
7
notes/src/string.md
Normal file
7
notes/src/string.md
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
# 总结
|
||||||
|
|
||||||
|
字符串局部翻转/旋转考虑先全局翻转,再局部翻转。
|
||||||
|
|
||||||
|
字符串原地插入/替换新字符,先扩展字符串的长度,然后双指针从后往前,按条件覆盖到慢指针。
|
||||||
|
|
||||||
|
Pattern 匹配考虑 KMP 算法。
|
Loading…
Reference in New Issue
Block a user