- Tree
- Prior: DFS BFS with Iteration/Recursion
- Traversal
- In-order
- Pre-order
- Post-order
- Layer
- Balanced Tree
- Red-Black Tree
- B+ Tree
- Trie
- Graph
- Topological Sort
- hashmap
- heap
- stack
- Monotonic
- queue
- circular
- Monotonic
- linked list
- double linked list
- Union Find
- LRU
- Dynamic Programming
- Digit DP
- Path DP
- Memorization
- Union Find / Disjoint Set
- Sorting
- Bubble
- Selection
- Insertion
- Quick
- Shell
- Merge
- Heap
- Bucket?
- Radix
- Counting
- Backtracking
- Sliding Window
- Bit Manipulation
- Greedy
- Prefix Sum
- Combinatorics
- String
- KMP
- SQL
- ACM 输入输出,链表/树/图的构建
设计模式,单例,工厂 生产者消费者
背包问题 回溯 组合问题, 子集问题, 手动实现哈希表 bat实现randombox,以时间为种子
回溯 Backtracking
77组合 78子集
5 最长回文子串 516 最长回文子序列 手写快排,非递归的快排 堆的实现
手写死锁 线程锁
买卖股票123
生产者消费者模型 条件变量生产者消费者 无锁队列CAS实现生产者消费者
DP 718 72编辑距离
595_BigCountries 1757_RecyclableAndLowFatProducts
108_ConvertSotedArraytoBinarySearchTree
1217_MinimumCosttoMoveChipstoTheSamePosition
287_FindtheDuplicateNumber 1 hashmap 1.1 see array as a hashmap 1.2 set to negative 2 sort() 3 set() 4.1 oneliner 4 find circle in listnode (same idea as 142) 5 modified binary search using pigeonhole principle 6 bit manipulation (the same idea as 1.1 but in a cleaner bitwise format)
300_LongestIncreasingSubsequence
42[]
138[]
167_TwoSumII_InputArrayisSorted
26_RemoveDuplicatesfromSortedArray
Backwards two pointer 88_MergeSortedArray
83_RemoveDuplicatesfromSortedList
1290_ConvertBinaryNumberinaLinkedListtoInterger
160_IntersectionofTwoLinkedLists
138[]
83_RemoveDuplicatesfromSortedList
108_ConvertSotedArraytoBinarySearchTree
144_BinaryTreePreorderTraversal
145_BinaryTreePostorderTraversal
108_ConvertSotedArraytoBinarySearchTree
26_RemoveDuplicatesfromSortedArray
https://oi-wiki.org/string/kmp/
144_BinaryTreePreorderTraversal
145_BinaryTreePostorderTraversal
Binary Search +1 -1
BFS queue
DFS stack
KMP Rabin Karp String match
two-pointer slow&fast tortoise&hare(rabbit)
permutation == anagram == same letter frequqncy
monotonic queue/stack
alphabet dictionary are super useful
sort()
min(a,key=len)
get min or max with different keys
collections.deque()
appendleft()
a stanford teacher https://keithschwarz.com/ https://keithschwarz.com/interesting/code/?dir=find-duplicate