# Leetcode-Complete-Guide **Repository Path**: laodasbch/Leetcode-Complete-Guide ## Basic Information - **Project Name**: Leetcode-Complete-Guide - **Description**: No description available - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 1 - **Forks**: 0 - **Created**: 2020-12-23 - **Last Updated**: 2024-01-27 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README ## [C++ Crash Course](./cpp)

# LeetCode 题解 + 报告 :memo: 题目会有我给予的相对难度评价 :heavy_plus_sign: CF的估测难度对应分数
## CF 分目测评估: :green_book: **800-1100** 对应 Easy **(E)**
:orange_book: **1200-1700** 对应 Medium **(M)**
:closed_book: **1700 - 2100** 对应 Hard **(H)**
***(代码以 C++ 和 Java 进行题解)***

## 程序员面试经典 (Wait for Update...) | # | Title | Difficulty | |-----|---------------- | --------------- | | 1 | [判定字符是否唯一](./interview/01.txt) | (E) 800 | | 2 | [ 判定是否互为字符重排](./interview/02.txt) | (E) 800 | | 3 | [ URL化 ](./interview/03.txt) | (E) 800 | | 4 | [ 回文排列 ](./interview/04.txt) |(E) 900| ## Premium | # | Title | Difficulty | | # | Title | Difficulty | |-----|---------------- | --------------- | -----|-----|---------------- | --------------- | | 243 |[Shortest Word Distance](./code/243.txt) | (E) 900|| 244 |[Shortest Word Distance II](./code/244.txt) | (M-) 1400| | 245 |[Shortest Word Distance III](./code/245.txt) | (M-) 1300|| 246 |[Strobogrammatic Number ](./code/246.txt) | (E) 900| | 247 |[Strobogrammatic Number II ](./code/247.txt) | (M) 1500|| 248 |[Strobogrammatic Number III ](./code/248.txt) | (H-) 1700| | 250 |[Count Univalue Subtrees ](./code/250.txt) | (M-) 1300| | 252 |[Meeting Rooms ](./code/252.txt) |(E) 900| | 253 |[Meeting RoomsII ](./code/253.txt) | (M) 1500| | 256 | [Paint House](./code/256.txt) | (M-) 1400| | 261 | [ Graph Valid Tree](./code/261.txt) | (M-) 1400|| 265 | [Paint House II](./code/265.txt) | (H-) 1700| | 266 |[Palindrome Permutation](./code/266.txt) | (E) 900|| 267 |[Palindrome Permutation II](./code/267.txt) | (M) 1500| | 270 |[ Closest Binary Search Tree Value](./code/270.txt) | (E) 1000| | 277 |[Find the Celebrity](./code/277.txt) | (M) 1500|| 286 |[Walls and Gates ](./code/286.txt) |(M-) 1400| | 291 |[Word Pattern II ](./code/291.txt) |(H) 1800| | 293 |[Flip Game ](./code/293.txt) |(E) 800| | 296 |[Best Meeting Point ](./code/296.txt) |(H-) 1700|| 294 |[Flip Game II(MIN_MAX)](./code/294.txt) | (M) 1500 | | 305 |[Number of Islands II](./code/305.txt) | (H-) 1700 || 323 |[Number of Connected Components in an Undirected Graph](./code/323.txt) | (M-) 1500 | | 325 |[ Maximum Size Subarray Sum Equals k](./code/325.txt) | (M-) 1300 || 339 |[ Nested List Weight Sum](./code/339.txt) | (E) 1000 | | 340 |[Longest Substring with At Most K Distinct Characters](./code/340.txt) | (H-) 1600 | | 360 |[Sort Transformed Array ](./code/360.txt) |(E) 1000| | 370 |[Range Addition](./code/370.txt)| (M) 1500 || 379 |[Design Phone Directory](./code/379.txt)| (M-) 1200 | | 411 |[Minimum Unique Word Abbreviation](./code/411.txt)| (H) 1800 || 422 |[Valid Word Square](./code/422.txt)| (E) 1000 | | 425 |[Word Squares](./code/425.txt) | (H) 1800 || 465 |[Optimal Account Balancing](./code/465.txt) | (H) 1800 | | 471 |[Encode String with Shortest Length (String + Interval DP)](./code/471.txt) | (H) 1900 || 487 |[Max Consecutive Ones II](./code/487.txt)| (M-) 1300 | | 531 |[Lonely Pixel I](./code/531.txt) | (M-) 1400 || 544 |[Output Contest Matches ](./code/544.txt) | (M) 1500 | | 545 |[Boundary of Binary Tree ](./code/545.txt) | (M) 1500 || 548 |[Split Array with Equal Sum ](./code/548.txt) | (M) 1500 | | 568 |[Maximum Vacation Days ](./code/568.txt) | (H-) 1700 | | 582 |[Kill Process ](./code/582.txt) | (M-) 1400 | | 624 |[Maximum Distance in Arrays ](./code/624.txt) | (M-) 1400 | | 644 |[Maximum Average Subarray II ](./code/644.txt) | (H) 1800 || 651 |[4 Keys Keyboard](./code/651.txt) | (M+) 1600 | | 683 |[ K Empty Slots ](./code/683.txt) | (H--) 1500 || 702 |[Search in a Sorted Array of Unknown Size ](./code/702.txt)| (M-) 1200 | | 716 |[Max Stack ](./code/716.txt)| (E+) 1200 || 750 |[ Number Of Corner Rectangles ](./code/750.txt)| (M) 1500 | | 755 |[Pour Water ](./code/755.txt)| (M-) 1400 | | 759 |[Employee Free Time ](./code/759.txt)| (H-) 1600 || 760 |[ Find Anagram Mappings ](./code/760.txt)| (E) 900 | | 774 |[Minimize Max Distance to Gas Station ](./code/774.txt)| (H-) 1700 || 1004 |[Max Consecutive Ones III](./code/1004.txt)| (M-) 1300 | | 1055 |[Shortest Way to Form String](./code/1055.txt)| (M-) 1300 || 1056 |[Confusing Number](./code/1056.txt)| (E) 900 | | 1061 |[Lexicographically Smallest Equivalent String](./code/1061.txt)| (M) 1500 | | 1063 |[Number of Valid Subarrays](./code/1063.txt)| (H-) 1600 | | 1064 |[Fixed Point](./code/1064.txt)| (E-) 600 || 1066 |[Campus Bikes II](./code/1066.txt)| (M+) 1600 | | 1067 |[ Digit Count in Range(Math)](./code/1067.txt)| (H+) 2000 | | 1085 |[Sum of Digits in the Minimum Number](./code/1085.txt)| (E) 800 | | 1099 |[Two Sum Less Than K](./code/1099.txt)| (E) 800 | | 1100 |[Find K-Length Substrings With No Repeated Characters](./code/1100.txt)| (M-) 1200 || 1101 |[The Earliest Moment When Everyone Become Friends](./code/1101.txt)| (M) 1500 | 1119 |[Remove Vowels from a String](./code/1119.txt)| (E-) 700 || 1121 |[Divide Array Into Increasing Sequences (Greedy)](./code/1121.txt)| (H-) 1700 | | 1135 |[Connecting Cities With Minimum Cost](./code/1135.txt)| (M-) 1400 | | 1136 |[Parallel Courses](./code/1136.txt)| (H-) 1600 || 1150 |[Check If a Number Is Majority Element in a Sorted Array](./code/1150.txt) | (E) 900 | | 1151 |[Minimum Swaps to Group All 1's Together](./code/1151.txt) | (M-) 1200 || 1167 |[Minimum Cost to Connect Sticks](./code/1167.txt) | (M-) 1400 | | 1168 |[Optimize Water Distribution in a Village](./code/1168.txt) | (H) 1800 || 1180 |[Count Substrings with Only One Distinct Letter](./code/1180.txt) | (E) 1000 | | 1196 | [How Many Apples Can You Put into the Basket](./code/1196.txt) | (E) 800 || 1183 |[Maximum Number of Ones](./code/1183.txt) |(H) 1800 | | 1216 |[Valid Palindrome III (区间dp)](./code/1216.txt) | (H-) 1700 || 1229 |[Meeting Scheduler](./code/1229.txt) | (M-) 1400 | | 1243 |[Array Transformation ](./code/1243.txt) | (E) 900 || 1244 |[Design A Leaderboard](./code/1244.txt) | (M-) 1200 | | 1246 |[Palindrome Removal (区间dp)](./code/1246.txt) |(H) 1800 | | 1251 |[Stepping Numbers (M-) 1400](./code/1251.txt) |(M-) 1400 | | 1257 |[Smallest Common Region (LCA)](./code/1257.txt) |(M) 1500 || 1273 |[Delete Tree Nodes](./code/1273.txt) |(M) 1500 | | 1259 |[Handshakes That Don't Cross ](./code/1259.txt) |(H-) 1700 || 1426 |[Counting Elements ](./code/1426.txt) |(E) 900 | | 1429 |[First Unique Number ](./code/1429.txt) |(M) 1500 || 1469 |[Find All The Lonely Nodes](./code/1469.txt) |(E) 900 | | 1474 |[ Delete N Nodes After M Nodes of a Linked Lists](./code/1474.txt) |(E) 1000 || 1485 |[Clone Binary Tree With Random Pointer](./code/1485.txt) |(M) 1500 | | 1506 |[Find Root of N-Ary Tree](./code/1506.txt) |(M-) 1300 || 1522 |[Diameter of N-Ary Tree](./code/1522.txt) |(M-) 1300 | | 1554 |[Strings Differ by One Character](./code/1554.txt) |(M-) 1400 || 1564 |[Put Boxes Into the Warehouse I](./code/1564.txt) |(M) 1500 | | 1570 |[Dot Product of Two Sparse Vectors](./code/1570.txt) |(M-) 1200 || 1580 |[Put Boxes Into the Warehouse II](./code/1580.txt) |(M+) 1600 | | 1602 |[Find Nearest Right Node in Binary Tree ](./code/1602.txt) |(M-) 1300 || 1612 |[Check If Two Expression Trees are Equivalent ](./code/1612.txt) |(M-) 1300 | | 1634 |[ Add Two Polynomials Represented as Linked Lists](./code/1634.txt) | (M-) 1400 || 1644 |[ Lowest Common Ancestor of a Binary Tree II](./code/1644.txt) | (M-) 1400 | | 1650 |[ Lowest Common Ancestor of a Binary Tree III](./code/1650.txt) | (M-) 1400 || 1660 |[ Correct a Binary Tree](./code/1660.txt) | (M-) 1400 | --- ### Array #27. [Remove Element (E) 800](./code/27.txt)
#41. [First Missing Positive (H-) 1600](./code/41.txt)
#54. [Spiral Matrix (M-) 1400](./code/54.txt)
#134. [Gas Station (M-) 1400](./code/134.txt)
#189. [Rotate Array(M) 1500](./code/189.txt)
#228. [Summary Ranges(E) 1000](./code/228.txt)
#268. [Missing Number(E) 900](./code/268.txt)
#349. [ Intersection of Two Arrays(E) 900](./code/349.txt)
#350. [ Intersection of Two Arrays II(E) 900](./code/350.txt)
#414. [Third Maximum Number (E) 900](./code/414.txt)
#419. [Battleships in a Board(M-) 1300](./code/419.txt)
#442. [Find All Duplicates in an Array (M-) 1400](./code/442.txt)
#495. [Teemo Attacking (M-) 1200](./code/495.txt)
#665. [ Non-decreasing Array (E+) 1200](./code/665.txt)
#795. [Number of Subarrays with Bounded Maximum (M) 1500](./code/795.txt)
#797. [All Paths From Source to Target (M) 1500](./code/797.txt)
#849. [Maximize Distance to Closest Person (M-) 1400](./code/849.txt)
#852. [Peak Index in a Mountain Array (E) 800](./code/852.txt)
#867. [Transpose Matrix (E) 900](./code/867.txt)
#905. [Sort Array By Parity (E) 800](./code/905.txt)
#944. [Delete Columns to Make Sorted (E) 900](./code/944.txt)
#1144. [Decrease Elements To Make Array Zigzag (M) 1500](./code/1144.txt)
#1331. [ Rank Transform of an Array (E) 1000](./code/1331.txt)
#1380. [Lucky Numbers in a Matrix (E) 900](./code/1380.txt)
#1572. [Matrix Diagonal Sum (E) 800](./code/1572.txt)
#1582. [Special Positions in a Binary Matrix(E) 900](./code/1582.txt)
#1588. [Sum of All Odd Length Subarrays(E) 800](./code/1588.txt)
#1589. [ Maximum Sum Obtained of Any Permutation (M) 1500](./code/1589.txt)
#1646. [ Get Maximum in Generated Array (E) 800](./code/1646.txt)
#1652. [ Defuse the Bomb (E) 900](./code/1652.txt)
--- ### BFS #117. [Populating Next Right Pointers in Each Node II (M) 1400](./code/117.txt)
#310. [Minimum Height Tree (M+) 1600](./code/310.txt)
#433. [Minimum Genetic Mutation (M) 1500](./code/433.txt)
#542. [01 Matrix (M) 1500](./code/542.txt)
#675. [Cut Off Trees for Golf Event (H-) 1700](./code/675.txt)
#766. [Toeplitz Matrix (M) 1400](./code/766.txt)
#847. [Shortest Path Visiting All Nodes (H) 1800](./code/847.txt)
#854. [K-Similar String (H) 1800](./code/854.txt)
#994. [Rotting Orange (M) 1400](./code/994.txt)
#1036. [Escape a Large Maze (H) 1800](./code/1036.txt)
#1298. [Maximum Candies You Can Get from Boxes (H-) 1700](./code/1298.txt)
#1329. [Sort the Matrix Diagonally (M) 1500](./code/1329.txt)
#1439. [Find the Kth Smallest Sum of a Matrix With Sorted Rows (H) 1800](./code/1439.txt)
#1625. [Lexicographically Smallest String After Applying Operations (M) 1500](./code/1625.txt)
#1631. [Path With Minimum Effort (M) 1500](./code/1631.txt)
#1654. [Minimum Jumps to Reach Home(M+) 1600](./code/1654.txt)
#LCP 09. [最小跳跃次数 (H) 1800](./code/LCP09.txt)
--- ### DFS #17. [Letter Combinations of a Phone Number (M-) 1400](./code/17.txt)
#39. [Combination Sum (M-) 1400](./code/39.txt)
#40. [Combination Sum II (M-) 1400](./code/40.txt)
#130. [ Surrounded Regions (M-) 1400](./code/130.txt)
#131. [Palindrome Partitioning (M) 1500](./code/131.txt)
#216. [Combination Sum III (M-) 1400](./code/216.txt)
#301. [Remove Invalid Parentheses (H-) 1600](./code/301.txt)
#306. [Additive Number (M) 1500](./code/306.txt)
#417. [Pacific Atlantic Water Flow (M+) 1600](./code/417.txt)
#473. [Matchsticks to Square (M+) 1600](./code/473.txt)
#488. [Zuma Game (H) 1800](./code/488.txt)
#491. [Increasing Subsequences (M) 1500](./code/491.txt)
#565. [Array Nesting (M-) 1400](./code/565.txt)
#690. [Employee Importance (M-) 1200](./code/690.txt)
#761. [Special Binary String (H) 1800](./code/761.txt)
#838. [ Push Dominoes (M) 1500](./code/838.txt)
#842. [ Split Array into Fibonacci Sequence(M+) 1600](./code/842.txt)
#967. [Numbers With Same Consecutive Differences (M) 1500](./code/967.txt)
#979. [Distribute Coins in Binary Tree (M+) 1600](./code/979.txt)
#988. [ Smallest String Starting From Leaf (M) 1500](./code/988.txt)
#1020. [Number of Enclaves (M-) 1400](./code/1020.txt)
#1239. [Maximum Length of a Concatenated String with Unique Characters (M) 1500](./code/1239.txt)
#1240. [Tiling a Rectangle with the Fewest Squares (H+) 2000](./1240.txt)
#1255. [Maximum Score Words Formed by Letters (H-) 1700](./code/1255.txt)
#1377. [Frog Position After T Seconds (M+) 1600](./code/1377.txt)
#1559. [Detect Cycles in 2D Grid (H-) 1700](./code/1559.txt)
#1601. [Maximum Number of Achievable Transfer Requests (H-) 1700](./code/1601.txt)
#LCP7. [传递信息 (M) 1400](./code/LCP7.txt)
--- ### Stack #56. [Merge Intervals (M-) 1400](./code/56.txt)
#57. [Insert Interval(M-) 1400](./code/57.txt)
#84. [Largest Rectangle in Histogram (H-) 1700](./code/84.txt)
#94. [Binary Tree Inorder Traversal (M-) 1400](./code/94.txt)
#150. [Evaluate Reverse Polish Notation (M) 1500](./code/150.txt)
#316. [Remove Duplicate Letters (M+) 1600](./code/316.txt)
#682. [Baseball Game (E+) 1100](./code/682.txt)
#735. [Asteroid Collision (M-) 1400](./code/735.txt)
#1003. [Check If Word Is Valid After Substitutions (M-) 1400](./code/1003.txt)
#1047. [Remove All Adjacent Duplicates In String (E) 1000](./code/1047.txt)
#1063. [Number of Valid Subarrays (H-) 1700](./code/1063.txt)
#1081. [Smallest Subsequence of Distinct Characters (M+) 1600](./code/1081.txt)
#1190. [Reverse Substrings Between Each Pair of Parentheses (M-) 1400](./code/1190.txt)
#1209. [Remove All Adjacent Duplicates in String II (M-) 1400](./code/1209.txt)
#1249. [Minimum Remove to Make Valid Parentheses (M-) 1400](./code/1249.txt)
#1544. [Make The String Great (E+) 1100](./code/1544.txt)
#1614. [Maximum Nesting Depth of the Parentheses (E) 900](./code/1614.txt)
--- ### LinkedList Note: LinkedList can be used as stack or queue or deque

#2. [Add Two Numbers (M-) 1300](./code/2.txt)
#19. [ Remove Nth Node From End of List (M-) 1400](./code/19.txt)
#24. [ Swap Nodes in Pairs (M) 1500](./code/24.txt)
#82. [Remove Duplicates from Sorted List II (M-) 1300](./code/82.txt)
#83. [Remove Duplicates from Sorted List (E) 1000](./code/83.txt)
#86. [Partition List (M-) 1300](./code/86.txt)
#92. [Reverse LinkedList II (M) 1500](./code/92.txt)
#141. [Linked List Cycle (E) 141](./code/1000.txt)
#146. [LRU Cache (M+) 1600](./code/146.txt)
#147. [Insertion Sort List (M-) 1200](./code/147.txt)
#203. [Remove Linked List Elements (E) 900](./code/203.txt)
#237. [Delete Node in a Linked List(E) 1000](./code/237.txt)
#328. [Odd Even Linked List (M-) 1300](./code/328.txt)
#341. [Flatten Nested List Iterator (M-) 1400](./code/341.txt)
#430. [Flatten a Multilevel Doubly Linked List (M) 1500](./code/430.txt)
#460. [LFU (H) 1800](./code/460.txt)
#817. [Linked List Components (M-) 1300](./code/817.txt)
#876. [Middle of the Linked List (E) 900](./code/876.txt)
#950. [Reveal Cards In Increasing Order (M) 1500](./code/950.txt)
--- ### Greedy #45. [Jump Game II (H-) 1600](./code/45.txt)
#135. [Candy (H-) 1700](./code/135.txt)
#218. [Skyline Problem (H) 1800](./code/218.txt)
#253. [Meeting Room II (M) 1500](./code/253.txt)
#406. [Queue Reconstruction by Height (M) 1500](./code/406.txt)
#435. [Non-overlapping Intervals (M) 1500](./code/435.txt)
#452. [Minimum Number of Arrows to Burst Balloonss (M) 1500](./code/452.txt)
#522. [Longest Uncommon Subsequence II (M-) 1300](./code/522.txt)
#556. [Next Greater Element III (M) 1500](./code/556.txt)
#630. [Course Schedule III (H-) 1700](./code/630.txt)
#699. [Falling Squares (H-) 1700](./code/699.txt)
#729. [My Calendar I (M) 1500](./code/729.txt)
#731. [My Calendar II (M+) 1600](./code/731.txt)
#763. [Partition Labels (M) 1500](./code/763.txt)
#765. [Couple Holding Hands (H-) 1600](./code/765.txt)
#767. [Reorganize String (M) 1500](./code/767.txt)
#857. [Minimum Cost to Hire K Workers (H) 1800](./code/857.txt)
#861. [Score After Flipping Matrix (M) 1500](./code/861.txt)
#870. [ Advantage Shuffle (M) 1500 (sort+2 pointer)](./code/870.txt)
#910. [Smallest Range II (H-) 1700](./code/910.txt)
#1007. [Minimum Domino Rotations For Equal Row (M) 1500](./code/1007.txt)
#1029. [Two City Scheduling (M+) 1600](./code/1029.txt)
#1111. [ Maximum Nesting Depth of Two Valid Parentheses Strings (M+) 1600](./code/1111.txt)
#1121. [Divide Array Into Increasing Sequence (H-) 1700](./code/1121.txt)
#1199. [Minimum Time Building Block (H) 1800](./code/1199.txt)
#1288. [Remove Covered Intervals (M-) 1400](./code/1288.txt)
#1296. [Divide Array in Sets of K Consecutive Numbers (M-) 1400](./code/1296.txt)
#1326.[Minimum Number of Taps to Open to Water a Garden (H) 1800](./code/1326.txt)
#1328.[Break a Palindrome (M-) 1300](./code/1328.txt)
#1383.[Maximum Performance of a Team (H-) 1700](./code/1383.txt)
#1414.[Find the Minimum Number of Fibonacci Numbers Whose Sum Is K (M+) 1600](./code/1414.txt)
#1432.[Max Difference You Can Get From Changing an Integer (M-) 1400](./code/1432.txt)
#1520.[Maximum Number of Non-Overlapping Substrings (H) 1900](./code/1520.txt)
#1540.[Can Convert String in K Moves (M) 1500](./code/1540.txt)
#1591.[Strange Printer II (H) 1800](./code/1591.txt)
#1605.[Find Valid Matrix Given Row and Column Sums (M+) 1700](./code/1605.txt)
#1632.[Rank Transform of a Matrix (H+) 2000](./code/1632.txt)
#1642.[Furthest Building You Can Reach (M+) 1600](./code/1642.txt)
#1663.[Smallest String With A Given Numeric Value (M-) 1400](./code/1663.txt)
#1665. [Minimum Initial Energy to Finish Tasks (H-) 1700](./code/1665.txt)
#LCP 06. [拿硬币 (E) 800](./code/LCP06.txt)
--- ### Graph #126. [Word Ladder II(H) 1900](./code/126.txt)
#133. [Clone Graph(M) 1500](./code/133.txt)
#785. [Is Graph Bipartite?(M) 1500](./code/785.txt)
#802. [Find Eventual Safe States(M+) 1700](./code/802.txt)
#863. [All Nodes Distance K in Binary Tree(M) 1500](./code/863.txt)
#886. [Possible Bipartition(M) 1500](./code/886.txt)
#1042. [Flower Planting With No Adjacent(E+) 1300](./code/1042.txt)
#1153. [String Transform into another String (H-) 1700](./code/1153.txt)
#1192. [Critical Connection (H) 1900](./code/1192.txt)
#1245. [Tree Diameter (M-) 1400](./code/1245.txt)
#1334. [Find the City With the Smallest Number of Neighbors at a Threshold Distance (M) 1500 (Floyd-Warshall)](./code/1334.txt)
#1361. [Validate Binary Tree Nodes (M) 1500](./code/1361.txt)
#1522. [Diameter of N-Ary Tree (M-) 1300](./code/1522.txt)
#1568. [Minimum Number of Days to Disconnect Island (H-) 1700](./code/1568.txt)
#1615. [Maximal Network Rank (M) 1500](./code/1615.txt)
--- ### Maxflow - Bipartite Matching (二分图匹配) 1. The size of a maximum flow in the resulting graph equals the size of a maximum matching in the original graph.
2. Size of a minimum node cover always equals the size of a maximum matching.
3. The complement of a maximum independent set is a minimum vertex cover(MAX Flow).
Reference : https://ali-ibrahim137.github.io/competitive/programming/2020/01/02/maximum-independent-set-in-bipartite-graphs.html
最大流: https://blog.csdn.net/chinacoy/article/details/45040897
#1349. [Maximum Students Taking Exam (H+) 2000](./code/1349.txt)
#LCP04. [覆盖 (H+) 2000](./code/LCP04.txt)
--- ### Binary Search #34. [Find First and Last Position of Element in Sorted Array (M-) 1300](./code/34.txt)
#35. [Search Insert Position (E) 1000](./code/35.txt)
#69. [Sqrt(x) (E+) 1100](./code/69.txt)
#153. [Find Minimum in Rotated Sorted Array (M+) 1600](./code/153.txt)
#154. [Find Minimum in Rotated Sorted Array II (H-) 1700](./code/154.txt)
#302. [包含全部黑色像素的最小矩形 (H-) 1700](./code/302.txt)
#352. [ Data Stream as Disjoint Intervals (H-) 1700](./code/352.txt)
#373. [Find K Pairs with Smallest Sums (M) 1500](./code/373.txt)
#374. [Guess Number Higher or Lower (E) 800](./code/374.txt)
#436. [ Find Right Interval (M) 1500](./code/436.txt)
#475. [Heaters (M) 1500](./code/475.txt)
#704. [Binary Search(E) 900](./code/704.txt)
#744. [Find Smallest Letter Greater Than Target (M-) 1200](./code/744.txt)
#786. [K-th Smallest Prime Fraction (H) 1800](./code/786.txt)
#792. [Number of Matching Subsequences (M+) 1600](./code/792.txt)
#911. [Online Election(M) 1500](./code/911.txt)
#1095. [Find in Mountain Array (H-) 1700](./code/1095.txt)
#1292. [Maximum Side Length of a Square with Sum Less than or Equal to Threshold (M+) 1600](./code/1292.txt)
#1533. [Find the Index of the Large Integer (M) 1500](./code/1533.txt)
#1552. [Magnetic Force Between Two Balls (M+) 1600](./code/1552.txt)
#1574. [ Shortest Subarray to be Removed to Make Array Sorted (M+) 1600](./code/1574.txt)
#LCP08. [剧情触发时间 (M) 1600](./code/LCP08.txt)
#LCP12. [小张刷题计划 (M) 1500](./code/LCP12.txt)
--- ### Tree #95. [ Unique Binary Search Trees II(M+) 1600](./code/95.txt)
#96. [ Unique Binary Search Trees (M+) 1600](./code/96.txt)
#98. [Validate Binary Search Tree (M) 1500](./code/98.txt)
#101. [Symmetric Tree (M-) 1300](./code/101.txt)
#110. [Balanced Binary Tree (E) 900](./code/110.txt)
#173. [Binary Search Tree Iterator (M) 1500](./code/173.txt)
#222. [ Count Complete Tree Nodes (M) 1500](./code/222.txt)
#235. [Lowest Common Ancestor of a Binary Search Tree (E+) 1100](./code/235.txt)
#236. [Lowest Common Ancestor of a Binary Tree (M-) 1400](./code/236.txt)
#257. [Binary Tree Paths (E) 1000](./code/257.txt)
#617. [Merge Binary Tree (E) 1000](./code/617.txt)
#623. [ Add One Row to Tree (M-) 1300](./code/623.txt)
#654. [Maximum Binary Tree (M-) 1400](./code/654.txt)
#669. [Trim a Binary Search Tree (M-) 1400](./code/669.txt)
#783. [Minimum Distance Between BST Nodes (E) 900](./code/783.txt)
#872. [Leaf-Similar Trees (E) 900](./code/872.txt)
#1026. [Maximum Difference Between Node and Ancestor (M-) 1400](./code/1026.txt)
#1080. [Insufficient Nodes in Root to Leaf Paths (M) 1500](./code/1080.txt)
#1110. [Delete Nodes And Return Forest (M-) 1400](./code/1110.txt)
#1123. [Lowest Common Ancestor of Deepest Leaves (M) 1500](./code/1123.txt)
#1339. [Maximum Product of Splitted Binary Tree (M) 1500](./code/1339.txt)
#1372. [Longest ZigZag Path in a Binary Tree (M) 1500](./code/1372.txt)
#1457. [Pseudo-Palindromic Paths in a Binary Tree (M-) 1300](./code/1457.txt)
#1490. [Clone N-tree (M-) 1300](./code/1490.txt)
#1516. [Move Sub-Tree of N-Ary Tree (H-) 1700](./code/1516.txt)
#1617. [Count Subtrees With Max Distance Between Cities (H) 1800](./code/1617.txt)
--- ### Trie #208. [Implement Trie (Prefix Tree) (M) 1500](./code/208.txt)
#211. [Design Add and Search Words Data Structure (M) 1500](./code/211.txt)
#421. [Maximum XOR of Two Numbers in an Array (M+) 1600](./code/421.txt)
--- ### DP #10. [Regular Expression Matching (H) 1900](./code/10.txt)
#44. [Wildcard Matching (H-) 1700](./code/44.txt)
#70. [Climbing Stairs (E) 900](./code/70.txt)
#85. [Maximal Rectangle (H-) 1700](./code/85.txt)
#91. [Decode Way (M+) 1700](./code/91.txt)
#97. [Interleaving String (H-) 1700](./code/97.txt)
#118. [Pascal's Triangle (E) 900](./code/118.txt)
#119. [Pascal's Triangle II (E) 1000](./code/119.txt)
#120. [Triangle (M-) 1300](./code/120.txt)
#123. [Best Time to Buy and Sell Stock III (H-) 1700](./code/123.txt)
#132. [Palindrome Partitioning II (H-) 1700](./code/132.txt)
#139. [Word Break (M) 1500](./code/139.txt)
#140. [Word Break II (H) 1800](./code/140.txt)
#188. [Best Time to Buy and Sell Stock IV (H) 1800](./code/188.txt)
#198. [House Robber (M) 1400](./code/198.txt)
#213. [House Robber II (M) 1500](./code/213.txt)
#279. [Perfect Square(M-) 1300](./code/279.txt)
#309. [Best Time to Buy and Sell Stock with Cooldown (M) 1500](./code/309.txt)
#312. [ Burst Balloons (H) 1800](./code/312.txt)
#322. [Coin Change (M-) 1400](./code/322.txt)
#363. [Max Sum of Rectangle No Larger Than K (M) 1800](./code/363.txt)
#403. [Frog Jump (H-) 1700](./code/403.txt)
#413. [Arithmetic Slices (M) 1500](./code/413.txt)
#446. [Arithmetic Slices II - Subsequence (H-) 1700](./code/446.txt)
#466. [Count Repetition (H) 1800](./code/466.txt)
#514. [Freedom Trail (H) 1800](./code/514.txt)
#518. [Coin Change 2 (M) 1500](./code/518.txt)
#691. [Stickers to Spell Word (H) 1900](./code/691.txt)
#714. [Best Time to Buy and Sell Stock with Transaction Fee (M+) 1600](./code/714.txt)
#717. [1-bit and 2-bit Characters (E) 1000](./code/717.txt)
#718. [Maximum Length of Repeated Subarray (M) 1500](./code/718.txt)
#727. [Minimum Window Subsequence (H) 1800](./code/727.txt)
#730. [Count Different Palindromic Subsequences (H) 1800](./code/730.txt)
#740. [Delete and Earn (M) 1500](./code/740.txt)
#741. [Cherry Pickup (H) 1800](./code/741.txt)
#764. [Largest Plus Sign (M) 1500](./code/764.txt)
#790. [Domino and Tromino Tiling(M+) 1700](./code/790.txt)
#798. [Smallest Rotation with Highest Score (H) 1900](./code/798.txt)
#801. [Minimum Swaps To Make Sequences Increasing (M+) 1600](./code/801.txt)
#805. [Split Array With Same Average (H) 1800](./code/805.txt)
#823. [Binary Trees With Factors (M) 1500](./code/823.txt)
#828. [Count Unique Characters of All Substrings of a Given String (H) 1900](./code/828.txt)
#837. [New 21 Game (M+) 1600](./code/823.txt)
#887. [Supper Egg drop (H) 1800](./code/887.txt)
#902. [Numbers At Most N Given Digit Set (H) 1800](./code/902.txt)
#903. [Valid Permutations for DI Sequence (H) 1800](./code/903.txt)
#918. [Maximum Sum Circular Subarray (M) 1500](./code/918.txt)
#920. [Number of Music Playlists (H) 1800](./code/920.txt)
#940. [Distinct Subsequences II (H) 1800](./code/940.txt)
#943. [Find the Shortest Superstring (H) 1900](./code/943.txt)
#968. [Binary Tree Camera (H+) 2000](./code/968.txt)
#983. [Minimum Cost For Tickets (M) 1500](./code/983.txt)
#1000. [Minimum Cost to Merge Stones (H+) 2000](./code/1000.txt)
#1012. [Numbers With Repeated Digits (H) 1800](./code/1012.txt)
#1027. [Longest Arithmetic Subsequence (M) 1500](./code/1027.txt)
#1029. [Two City Scheduling (M) 1500](./code/1029.txt)
#1039. [Minimum Score Triangulation of Polygon (M+) 1700](./code/1039.txt)
#1066. [Campus Bike II (H-) 1700](./code/1066.txt)
#1092. [Shortest Common Supersequenceg (H) 1800](./code/1092.txt)
#1137. [N-th Tribonacci Number (E) 900](./code/1137.txt)
#1139. [Largest 1-Bordered Square (M) 1600](./code/1139.txt)
#1155. [Number of Dice Rolls With Target Sum (M+) 1600](./code/1155.txt)
#1125. [Smallest Sufficient Team (H) 1800](./code/1125.txt)
#1259. [Handshakes That Don't Cross (H-) 1700](./code/1259.txt)
#1277. [Count Square Submatrices with All Ones (M) 1500](./code/1277.txt)
#1359. [Count All Valid Pickup and Delivery Options (H-) 1700](./code/1359.txt)
#1388. [Pizza With 3n Slices (H) 1800](./code/1388.txt)
#1402. [Reducing Dishes (H-) 1600](./code/1402.txt)
#1420. [Build Array Where You Can Find The Maximum Exactly K Comparisons(H) 1800](./code/1420.txt)
#1458. [Max Dot Product of Two Subsequences (H-) 1600](./code/1458.txt)
#1473. [Paint House III (H) 1800](./code/1473.txt)
#1478. [Allocate Mailboxes (H) 1900](./code/1478.txt)
#1546. [Maximum Number of Non-Overlapping Subarrays With Sum Equals Target (M+) 1600](./code/1546.txt)
#1548. [The Most Similar Path in a Graph (H) 1800](./code/1548.txt)
#1563. [Stone Game V (H-) 1700](./code/1563.txt)
#1563. [Number of Ways to Reorder Array to Get Same BST (H) 1900](./code/1569.txt)
#1575. [Count All Possible Routes (H) 1800](./code/1575.txt)
#1621. [Number of Sets of K Non-Overlapping Line Segments (M+) 1700](./code/1621.txt)
#1639. [Number of Ways to Form a Target String Given a Dictionary (H) 1800](./code/1639.txt)
#1641. [Count Sorted Vowel Strings (M-) 1400](./code/1641.txt)
#1653. [Minimum Deletions to Make String Balanced (M) 1500](./code/1653.txt)
#1655. [Distribute Repeating Integers(H) 1800](./code/1655.txt)
#1659. [Maximize Grid Happiness(H+) 2200](./code/1659.txt)
#LCP10. [二叉树任务调度 (H+) 2200](./code/LCP10.txt)
#LCP13. [寻宝 (H+) 2100](./code/LCP13.txt)
#LCP14. [切分数组 (H+) 2200](./code/LCP14.txt)
--- ### Math #60. [Permutation Sequence (M+) 1600](./code/60.txt)
#172. [Factorial Trailing Zeroes (M-) 1400](./code/172.txt)
#233. [Number of Digit One (H) 1900](./code/233.txt)
#396. [Rotate Function (M-) 1400](./code/396.txt)
#440. [ K-th Smallest in Lexicographical Order (H+) 1900](./code/440.txt)
#453. [Minimum Moves to Equal Array Elements (E+) 1100](./code/453.txt)
#463. [Island Perimeter (E) 900](./code/463.txt)
#553. [Optimal division (M-) 1300](./code/553.txt)
#598. [Range Addition II (E)) 900](./code/598.txt)
#799. [Champagne Tower(M) 1500](./code/799.txt)
#836. [Rectangle Overlap (E+) 1100](./code/836.txt)
#869. [Reordered Power of 2 (M-) 1300](./code/869.txt)
#880. [Decoded String at Index (M+) 1600](./code/880.txt)
#891. [Sum of Subsequence Widths (H) 1800](./code/891.txt)
#888. [Fair Candy Swap (E) 1000](./code/888.txt)
#908. [Smallest Range I (E+) 1100](./code/908.txt)
#957. [Prison Cells After N Days (M) 1500](./code/957.txt)
#976. [Largest Perimeter Triangle (E) 900](./code/976.txt)
#1006. [ Clumsy Factorial (M) 1500](./code/1006.txt)
#1018. [ Binary Prefix Divisible By 5 (E) 1000](./code/1018.txt)
#1024. [Vedio Stichting (M) 1600](./code/1024.txt)
#1041. [Robot Bounded In Circle (M) 1500](./code/1041.txt)
#1103. [ Distribute Candies to People(E+) 1300](./code/1103.txt)
#1128. [Number of Equivalent Domino Pairs (E) 1000](./code/1128.txt)
#1131. [Maximum of Absolute Value Expression (M+) 1600](./code/1131.txt)
#1237. [ Find Positive Integer Solution for a Given Equation (E) 1000](./code/1237.txt)
#1415. [ The k-th Lexicographical String of All Happy Strings of Length n (M+) 1600](./code/1415.txt)
#1465. [Maximum Area of a Piece of Cake After Horizontal and Vertical Cuts (M-) 1200](./code/1465.txt)
#1498. [Number of Subsequences That Satisfy the Given Sum Condition (M+) 1600](./code/1498.txt)
#1551. [Minimum Operations to Make Array Equal (M-) 1200](./code/1551.txt)
#1573. [Number of Ways to Split a String (M) 1500](./code/1573.txt)
#1622. [Fancy Sequence (H+) 2000](./code/1622.txt)
#1643. [Kth Smallest Instructions (H) 1800](./code/1643.txt)
#1648. [Sell Diminishing-Valued Colored Balls (M+) 1600](./code/1648.txt)
#LCP3. [机器人大冒险 (M) 1500](./code/LCP3.txt)
#LCP11. [期望个数统计 (M-) 1400](./code/LCP11.txt)
### Prefix Sum #1664. [Ways to Make a Fair Array (M) 1500](./code/1664.txt)
### Geometry #1610. [ Maximum Number of Visible Points(H) 1800](./code/1610.txt)
--- ### Moore's Voting #169. [Majority Element (M-) 1200](./code/169.txt)
#229. [Majority Element (M) 1500](./code/229.txt)
--- ### Segment Tree #308. [Range Sum Query 2D - Mutable (2D Segment Tree) (H) 2100](./code/308.txt)
#715. [Range Module (H) 1900](./code/715.txt)
#1505. [Minimum Possible Integer After at Most K Adjacent Swaps On Digits (BIT) (H) 1900](./code/1505.txt)
#1585. [Check If String Is Transformable With Substring Sort Operations (Segment Tree) (H+) 2400](./code/1585.txt)
#1649. [Create Sorted Array through Instructions (BIT) (H) 1800](./code/1649.txt)
#LCP5. [发leetcoin (H+) 2300](./code/LCP5.txt)
#b857. [Delete Integers In Ascending Order (BIT) (H) 1800](./code/b857.txt)
--- ### Sparse Table #1310. [XOR Queries of a Subarray (M) 1500](./code/1310.txt)
#1483. [Kth Ancestor of a Tree Node (H) 1800](./code/1483.txt)
--- ### Observation #667. [Beautiful Arrangement II (M) 1500](./code/667.txt)
#777. [Swap Adjacent in LR String (M+) 1600](./code/777.txt)
#899. [Orderly Queue (H-) 1700](./code/899.txt)
#1109. [Corporate Flight Bookings (M) 1500](./code/1109.txt)
#1538. [Guess the Majority in a Hidden Array (M+) 1700](./code/1538.txt)
--- ### Sliding Window #3. [Longest Substring Without Repeating Characters (M-) 1400](./code/3.txt)
#76. [Minimum Window Substring (M+) 1700](./code/76.txt)
#395. [Longest Substring with At Least K Repeating Characters (M+) 1700](./code/395.txt)
#424. [Longest Repeating Character Replacement (M) 1500](./code/424.txt)
#713. [Subarray Product Less Than K (M) 1500](./code/713.txt)
#904. [Fruit Into Baskets (M-) 1300](./code/904.txt)
#933. [Number of recent call (E) 1000](./code/933.txt)
#992. [Subarrays with K Different Integers (H) 1800](./code/992.txt)
#1040. [Moving Stones Until Consecutive II (M+) 1600](./code/1040.txt)
#1052. [Grumpy Bookstore Owner (M) 1500](./code/1052.txt)
#1156. [Swap For Longest Repeated Character Substring (M) 1500](./code/1156.txt)
#1208. [Get Equal Substrings Within Budget (M-) 1400](./code/1208.txt)
#1456. [Maximum Number of Vowels in a Substring of Given Length (M-) 1300](./code/1456.txt)
--- ### Two Pointer #80. [Remove Duplicates from Sorted Array II (M-) 1400](./code/80.txt)
#455. [Assign Cookies (E) 1000](./code/455.txt)
#524. [Longest Word in Dictionary through Deleting (M-) 1400](./code/524.txt)
#632. [Smallest Range Covering Elements from K Lists (H) 1800](./code/632.txt)
#881. [Boats to Save People (M-) 1400](./code/881.txt)
#923. [ 3Sum With Multiplicity (M+) 1600](./code/923.txt)
#925. [ Long Pressed Name (E) 1000](./code/925.txt)
#986. [Interval List Intersections (M) 1500](./code/986.txt)
--- ### Sort #179. [Largest Number (M) 1500](./code/179.txt)
#215. [Kth Largest Element in an Array (Quick Select) (M) 1500](./code/215.txt)
#252. [Meeting Room (E) 1000](./code/252.txt)
#295. [Find Median from Data Stream (H-) 1600](./code/295.txt)
#581. [Shortest Unsorted Continuous Subarray (E) 1000](./code/581.txt)
#791. [Custom Sort String (M-) 1300](./code/791.txt)
#955. [Delete Columns to Make Sorted II (M+) 1600](./code/955.txt)
#1030. [Matrix Cells in Distance Order (E) 900](./code/1030.txt)
#1366. [Rank Teams by Votes (M+) 1600](./code/1366.txt)
#1629. [Slowest Key (E) 900](./code/1629.txt)
#1636. [Sort Array by Increasing Frequency (E+) 1100](./code/1636.txt)
--- ### String #6. [ZigZag Conversion (M-) 1300](./code/6.txt)
#9. [Palindrom Number (E) 900](./code/9.txt)
#28. [Implement strStr(M) 1500 (KMP)](./code/28.txt)
#49. [ Group Anagrams (M-) 1300](./code/49.txt)
#151. [ Reverse Words in a String (M-) 1300](./code/151.txt)
#214. [Shortest Palindromem (H-) (KMP) 1700](./code/214.txt)
#242. [Valid Anagram (E) 900](./code/242.txt)
#290. [Word Pattern (E) 1000](./code/290.txt)
#336. [Palindrome Pairs (H) 1800](./code/336.txt)
#696. [Count Binary Substrings (E) 1000](./code/696.txt)
#833. [Find And Replace in String (M) 1500](./code/833.txt)
#811. [Subdomain Visit Count (E) 800](./code/811.txt)
#859. [ Buddy Strings (E) 1000](./code/859.txt)
#906. [Super Palindrom (H) 1800](./code/906.txt)
#936. [Stamping The Sequence (H+) 2300](./code/936.txt)
#953. [Verifying an Alien Dictionary (E) 1000](./code/953.txt)
#1163. [Last Substring in Lexicographical Order (H-) 1700](./code/1163.txt)
#1446. [Consecutive Characters (E) 900](./code/1446.txt)
#1616. [Split Two Strings to Make Palindrome (M+) 1600](./code/1616.txt)
#1624. [Largest Substring Between Two Equal Characters (E) 900](./code/1624.txt)
--- ### Game Theory #292. [Nime Game (M-) 1400](./code/292.txt)
#365. [Water and Jug Problem (M+) 1600](./code/365.txt)
#375. [Guess Number Higher or Lower II (M+) 1600](./code/375.txt)
#486. [Predict the Winner (M) 1500](./code/486.txt)
#521. [ Longest Uncommon Subsequence I (E) 800](./code/521.txt)
#789. [ Escape The Ghosts (M-) 1400](./code/789.txt)
#843. [Guess The World (H-) 1700](./code/843.txt)
#877. [Stone Game (M+) 1600](./code/877.txt)
#913. [Cat and Mouse (H+) 2400](./code/913.txt)
#1025. [Divisor Game (E+) 1100](./code/1025.txt)
#1140. [Stone Game II (M+) 1600](./code/1140.txt)
--- ### Implementation #7. [Reverse Integer (E) 900](./code/7.txt)
#26. [Remove Duplicates from Sorted Array (E) 800](./code/26.txt)
#68. [Text Justification (H) 1800](./code/68.txt)
#202. [Happy Number (E) 800](./code/202.txt)
#258. [Add Digits (E) 800](./code/258.txt)
#747. [Largest Number At Least Twice of Others (E) 900](./code/747.txt)
#806. [Number of Lines To Write String (E) 900](./code/806.txt)
#1071. [Greatest Common Divisor of Strings (E) 900](./code/1071.txt)
#1550. [Three Consecutive Odds (E-) 700](./code/1550.txt)
#1640. [Check Array Formation Through Concatenation (E) 1000](./code/1640.txt)
#1662. [Check If Two String Arrays are Equivalent (E) 800](./code/1662.txt)
--- ### Bit #201. [Bitwise AND of Numbers Range (M+) 1600](./code/201.txt)
#318. [Maximum Product of Word Lengths (M) 1500](./code/318.txt)
#898. [Bitwise ORs of Subarrays (M+) 1600](./code/898.txt)
#1178. [Number of Valid Words for Each Puzzle (H-) 1700](./code/1178.txt)
#1290. [Convert Binary Number in a Linked List to Integer (E) 900](./code/1290.txt)
#1371. [ Find the Longest Substring Containing Vowels in Even Counts (M) 1500](./code/1371.txt)
#1318. [ Minimum Flips to Make a OR b Equal to c (M) 1500](./code/1318.txt)
#1404. [ Number of Steps to Reduce a Number in Binary Representation to One (M+) 1600](./code/1404.txt)
#1611. [ Minimum One Bit Operations to Make Integers Zero (H) 1800](./code/1611.txt)
--- ### Hash #30. [Substring with Concatenation of All Words(H-) 1700](./code/30.txt)
#219. [Contains Duplicate II (E) 800](./code/219.txt)
#220. [Contains Duplicate III (M) 1500](./code/220.txt)
#409. [Longest Palindrom (E) 900](./code/409.txt)
#594. [Longest Harmonious Subsequence (E) 1000](./code/594.txt)
#804. [Unique Morse Code Words (E) 800](./code/804.txt)
#825. [Friends Of Appropriate Ages(M-) 1300](./code/825.txt)
#893. [ Groups of Special-Equivalent Strings (E) 1000](./code/893.txt)
#954. [Array of Doubled Pairs(M-) 1400](./code/954.txt)
#1267. [Count Servers that Communicate (M-) 1300](./code/1267.txt)
#1282. [Group the People Given the Group Size They Belong To (M-) 1300](./code/1282.txt)
#1396. [Design Underground System (M) 1500](./code/1396.txt)
--- ### Divide Conquer #315. [Count of Smaller Numbers After Self(H-) 1700](./code/315.txt)
#327. [Count of Range Sum(H) 1800](./code/327.txt)
#454. [4 sum II (M-) 1400](./code/454.txt)
#932. [Beautiful Array (M+) 1700](./code/932.txt)
--- ### Union Find #947. [Most Stones Removed with Same Row or Column (M) 1500](./code/947.txt)
#990. [Satisfiability of Equality Equations (M) 1500](./code/990.txt)
#1202. [Smallest String With Swaps (M+) 1600](./code/1202.txt)
#1579. [Remove Max Number of Edges to Keep Graph Fully Traversable (H) 1900](./code/1579.txt)
#1584. [Min Cost to Connect All Points (M) 1500](./code/1584.txt)
#1627. [Graph Connectivity With Threshold (H) 1800](./code/1627.txt)
--- ### Ordered Map #1606. [Find Servers That Handled Most Number of Requests(H) 1800](./code/1606.txt)
--- ### SQL #175. [Combine Two Tables (E)](./sql/175.txt)
#177. [Nth Highest Salary (M)](./sql/177.txt)
#180. [ Consecutive Numbers (M)](./sql/180.txt)
#181. [Employees Earning More Than Their Managers (E)](./sql/181.txt)
#182. [Duplicate Emails (E)](./sql/182.txt)
#183. [Customers Who Never Order (E)](./sql/183.txt)
#184. [Department Highest Salary (M)](./sql/184.txt)
#197. [Rising Temperature (E)](./sql/197.txt)
#511. [Game Play Analysis I (E)](./sql/511.txt)
#595. [Big Countries (E)](./sql/595.txt)
#596. [Classes More Than 5 Students (E)](./sql/596.txt)
#607. [Sales Person (E)](./sql/607.txt)
#620. [Not Boring Movie (E)](./sql/620.txt)
#1082. [Sales Analysis I (E)](./sql/1082.txt)
#1303. [Find the Team Size (E)](./sql/1303.txt)
#1407. [ Top Travellers (E)](./sql/1407.txt)
#1565. [Unique Orders and Customers Per Month (E)](./sql/1565.txt)
--- --- ### 力扣秋季赛 #LCP17. [速算机器人 (E) 900](./code/LCP17.txt)
#LCP18. [早餐组合 (M-) 1400](./code/LCP18.txt)
#LCP19. [秋叶收藏集 (M+) 1600](./code/LCP19.txt)
#LCP20. [快速公交 (H) 1800](./code/LCP20.txt)
#LCP21. [追逐游戏 (H) 1900](./code/LCP21.txt)
### 力扣2020秋季战队赛 #LCP22. [黑白方格画 (M) 1500](./code/LCP22.txt)
#LCP23. [魔术排列 (M+) 1600](./code/LCP23.txt)
#LCP24. [数字游戏 (H+) 2000](./code/LCP24.txt)
#LCP25. [古董键盘 (H) 1900](./code/LCP25.txt)
#LCP26. [导航装置 (H+) 2400](./code/LCP26.txt)
#LCP27. [ 黑盒光线反射 (H+) 2300](./code/LCP27.txt)
---

# :pushpin: ACM 练习 **精刷 200 题**
*参照以下 links:*
:link: https://github.com/yogykwan/acm-challenge-workbook
:link: https://blog.csdn.net/u011613729/article/details/9788669 --- ### Two pointer #POJ 2739. [Sum of Consecutive Prime Numbers (M) 1500](./code/POJ2739.txt)
--- ### DFS #POJ 1979. [ Red and Black (M-) 1400](./code/POJ1979.txt)
--- ### 枚举 #POJ 1753. [ Flip Game (H) 1800](./code/POJ1753.txt)
--- ### 反转(开关) #POJ 3185. [ The Water Bowls (M+) 1600](./code/POJ3185.txt)
--- ### Minimum Spanning Tree #POJ 1258. [ Agri-Net POJ (M) 1600](./code/POJ1258.txt)
--- ### Strong Connect Component (强连通) :link: **Source:** https://iq.opengenus.org/tarjans-algorithm/ (Tarjan for SCC)
**Tarjan 和Kosaraju’s 同等适用与找强连通**
#POJ 1236. [Network of Schools (H+) 2200](./code/POJ1236.txt)
#POJ 3713. [Transferring Sylla (H+) 2200](./code/POJ3713.txt)
--- ### Binary Search #POJ 3685. [Matrix (H) 1800](./code/POJ3685.txt)
--- ### DP #POJ 1159. [Palindrom (H-) 1700](./code/POJ1159.txt)
#POJ 1458. [Balance (M) 1500](./code/POJ1458.txt)
#POJ 1837. [Balance (H-) 1700](./code/POJ1837.txt)
#POJ 2229. [Sumsets (M) 1500](./code/POJ2229.txt)
#POJ 2479. [Maximum sum (M+) 1600](./code/POJ2479.txt)
--- ### 贪心 #POJ 1844. [Sum (M+) 1600](./code/POJ1844.txt)
#POJ 3614. [Sunscreen (H-) 1700](./code/POJ3614.txt)
--- ### 二分图匹配 #POJ 1274. [The Perfect Stall (H-) 1700](./code/POJ1274.txt)


--- # :link: BinarySearch.io ***一个不错新的面试刷题网站***
#B6. [Omitted (M-) 1400](./code/b6.txt)
#B11. [Unival Tree Count (M-) 1300](./code/b11.txt)
#B12. [Longest Substring with K Distinct Characters (H-) 1600](./code/b12.txt)
#B13. [Collecting Coins (M-) 1400](./code/b13.txt)
#B14. [Counting Dinosaurs (E) 900](./code/b14.txt)
#B15. [Tom Sawyer (M+) 1600](./code/b15.txt)
#B26. [Longest Palindromic Subsequence (H-) 1700](./code/b26.txt)
#B27. [LCS (M) 1500](./code/b27.txt)
#B44. [Largest Rectangle (H-) 1700](./code/b44.txt)
#B48. [Sunk Islands (M) 1500](./code/b48.txt)
#B58. [High Frequency (E) 900](./code/b58.txt)
#B76. [Making Coin Change (M-) 1300](./code/b76.txt)
#B81. [Tree Pruning (M-) 1400](./code/b81.txt)
#B83. [Climing down the tree (M-) 1400](./code/b83.txt)
#B87. [The quick brown fox (M+) 1600](./code/b87.txt)
#B88. [Connected Cities (H-) 1700](./code/b88.txt)
#B91. [Chunky strings (E) 900](./code/b91.txt)
#B94. [Detecting an odd length cycle (H) 1800](./code/b94.txt)
#B97. [Repeated Deletion (M-) 1400](./code/b97.txt)
#B106. [Unique subsequence (H-) 1700](./code/b106.txt)
#B111. [List Min Replacement (E) 1000](./code/b111.txt)
#B115. [Longest Zero Sublist Sum (M) 1500](./code/b115.txt)
#B129. [Pigeonhole (E+) 1100](./code/b129.txt)
#B190. [Minimum Bracket Addition (E) 1000](./code/b190.txt)
#B193. [Sum Tree (M-) 1300](./code/b193.txt)
#B200. [Odd number of digits (E-) 800](./code/b200.txt)
#B207. [Mad Max (H-) 1700](./code/b207.txt)
#B217. [Longest common subsequence of three strings (H) 1800](./code/b217.txt)
#B251. [Largest tree sum path (M+) 1600](./code/b251.txt)
#B277. [Unique Characters of Every Substring (H) 1800](./code/b277.txt)
#B286. [Minimum Difference (M)1500](./code/b286.txt)
#B299. [Subsequence Picking (H)1900](./code/b299.txt)
#B315. [Minimum Spanning Tree (H)1800](./code/b315.txt)
#B342. [Equal Piles (M-)1400](./code/b342.txt)
#B357. [Longest Alternating Subsequence (M)1500](./code/b357.txt)
#B358. [Bus Fare (M)1600](./code/b358.txt)
#B362. [Number Flip (E)900](./code/b362.txt)
#B372. [Longest Even Sum Path (H)1800](./code/b372.txt)
#B375. [The Meeting Place (M)1500](./code/b375.txt)
#B390. [Range Update (M)1500](./code/b390.txt)
#B424. [Outstanding Move (H-)1700](./code/b424.txt)
#B438. [0-1 Knapsack (M+)1600](./code/b438.txt)
#B459. [Anagram Substrings (M-) 1400](./code/b459.txt)
#B464. [Count Exact Sum (H-) 1700](./code/b464.txt)
#B503. [Small Large Medium (M+)1600](./code/b503.txt)
#B539. [Divisible Numbers (H)1800](./code/b539.txt)
#B591. [Connect Forest (H)1800](./code/b591.txt)
#B682. [Concatenated Sums (M)1500](./code/b682.txt)
#B687. [Candy Race with Different Types (M)1500](./code/b687.txt)
#B688. [Number of K-Divisible Sublists (M)1500](./code/b688.txt)
#B689. [Number of K-Length Sublists with Average at Least Target (M-)1300](./code/b689.txt)
#B690. [Partition List to Pairs that are Divisible by K (M-)1300](./code/b690.txt)
#B700. [Create Palindrome After Deleting at Most K Characters (H-)1700](./code/b700.txt)
#B701. [Minimum Size of Two Non-Overlapping Intervals (M)1500](./code/b701.txt)
#B703. [Genetic Mutation (M+)1600](./code/b703.txt)
#B708. [Maximum Additive Score by Removing Numbers (H-)1700](./code/b708.txt)
#B709. [Arrange Symbols to Create Sum (M+)1600](./code/b709.txt)
#B713. [Minimum Difference of Extremes (M-)1400](./code/b713.txt)
#B731. [Deleting Repeated Integers Game (M+)1600](./code/b731.txt)
#B733. [Matrix Prefix Sum (M-)1300](./code/b733.txt)
#B736. [Maximal Points from Deleting Two Character Substrings (H-)1700](./code/b736.txt)
#B741. [Graph Weight Queries (H)1800](./code/b741.txt)
#B742. [Even Frequency (E)800](./code/b742.txt)
#B744. [Lowest Sum of Pair Larger than Target(M-)1400](./code/b744.txt)
#B747. [Minimum Time to Finish K Tasks(H-)1700](./code/b747.txt)
#B748. [Maximum XOR Queries(H)1800 (Trie)](./code/b748.txt)
#B816. [Task Run(E+)1100 (Array)](./code/b816.txt)
#B818. [Non-Overlapping Pairs of Sublists(M+)1600 (Array)](./code/b818.txt)


--- # :punch: CodeForce Contest 统计(1800+ 题量): 98 ### Beta Round #3 B. [Lorry (1900)贪心 + sort ](./contest/BETA3B.txt)
D. [Least Cost Bracket Sequence (2600)贪心 ](./contest/BETA3D.txt)
### Beta Round #4 (Div. 2) A. [Watermelon (800) ](./contest/BETA4A.txt)
B. [Before an exam (1200) ](./contest/BETA4B.txt)
C. [Registration System (1200) ](./contest/BETA4C.txt)
D. [Mysterious Present (1700) DP](./contest/BETA4D.txt)
### Beta Round #25 (Div. 2) A. [ IQ test (1300) ](./contest/BETA25A.txt)
B. [ Phone Number (1100) ](./contest/BETA25B.txt)
C. [ Roads in Berland (1900) (Shortest path+path compression)](./contest/BETA25C.txt)
D. [Roads not only in Berland (1900) (Union Find) ](./contest/BETA25D.txt)
E. [Test(2200) (KMP) ](./contest/BETA25E.txt)
### Beta Round #34 (Div. 2) A. [ Reconnaissance 2 (800) ](./contest/BETA34A.txt)
B. [ Sale (900) ](./contest/BETA34B.txt)
D. [ Road Map (1600) Tree ](./contest/BETA34D.txt)
### Beta Round #40 (Div. 2) A. [ Translation (800) ](./contest/BETA40A.txt)
B. [ Martian Dollar (1400) ](./contest/BETA40B.txt)
C. [Email address (1300) ](./contest/BETA40C.txt)
D. [Pawn (1900) dp+打表](./contest/BETA40D.txt)
E. [3-Cycle (1900) (Graph+Thinking+Observation) ](./contest/BETA40E.txt)
### Beta Round #59 (Div. 2) A. [ Sinking Ship (800) ](./contest/BETA59A.txt)
B. [Settlers' Training (1200) ](./contest/BETA59B.txt)
C. [Bulls and Cows (1700) ](./contest/BETA59C.txt)
D. [Dividing Islands (1900) (Greedy+Implmentation) ](./contest/BETA59D.txt)
E. [Sweet Game (2000) (Game Theory+Matrix) ](./contest/BETA59E.txt)
### Beta Round #63 (Div. 2) A. [ Young Physicist1 (1000) ](./contest/BETA63A.txt)
B. [Bets (1200) ](./contest/BETA63B.txt)
D. [Dot (1900) (Game+Dp)](./contest/BETA63D.txt)
E. [Subsegments (1800) (Sliding Window)](./contest/BETA63E.txt)
### Beta Round #95 (Div. 2) A. [ cAPS lOCK (1000) ](./contest/BETA95A.txt)
B. [ Opposites Attract (1200) ](./contest/BETA95B.txt)
C. [ The World is a Theatre (1400) ](./contest/BETA95C.txt)
D. [ Subway (1600) (Graph Cycle)](./contest/BETA95D.txt)
E. [ Yet Another Task with Queens (1700) (2D Matrix Sort)](./contest/BETA95E.txt)
F. [ Present to Mom(2000) (2D Matrix + prefix + Siding window)](./contest/BETA95F.txt)
### Beta Round #98 (Div. 2) A. [ Postcards and photos (900) ](./contest/BETA98A.txt)
B. [Permutation (1000) ](./contest/BETA98B.txt)
C. [History (1500) ](./contest/BETA98C.txt)
D. [Palindromes (1900) (DP)](./contest/BETA98D.txt)
E. [Last Chance (2000) (Segment Tree + prefix sum)](./contest/BETA98E.txt)
### Codeforces Round #150 (Div. 1) A. [The Brand New Function (1600) ](./code/150A.txt)
B. [Hydra (2000) (集合相交)](./code/150B.txt)
### Codeforces Round #218 (Div. 2) 371A.[K-Periodic Array (Greedy) (1000) ](./easy/371A.txt)
371B.[Fox Dividing Cheese (Math) (1300) ](./easy/371B.txt)
371C. [Hamburgers (Binary Search + Math) (1600) ](./cf/371C.txt)
371D. [Vessels (Ordered Map) (1800) ](./cf/371D.txt)
371E. [Subway Innovation (Prefix Sum+Math) (2000) ](./cf/371E.txt)
### Codeforces Round #295 (Div. 2) A. [Pangram (800) ](./code/295A.txt)
B. [Two Buttons (1400) ](./code/295B.txt)
C. [DNA Alignment (1500) (Math+Observation) ](./code/295C.txt)
E. [Pluses everywhere (2200) (Math+组合数学) ](./code/295E.txt)
### Codeforces Round #306 (Div. 2) A. [Two Substrings (1500) (dp) ](./code/306A.txt)
B. [Preparing Olympiad (1400) (BitMask+BruteForce) ](./code/306B.txt)
C. [ Divisibility by Eight (1500) ](./code/306C.txt)
D. [ Regular Bridge (1900) (Graph+Math) ](./code/306D.txt)
E. [ Brackets in Implications (2200) (Implementation+Math) ](./code/306E.txt)
### Codeforces Round #550 (Div. 3) A. [Diverse Strings (800) ](./code/550A.txt)
B. [Parity Alternated Deletions (900)](./code/550B.txt)
C. [Two Shuffled Sequences (1000)](./code/550C.txt)
D. [Equalize Them All (1400) (排序)](./code/550D.txt)
E. [Median String (1900) (数学位算)](./code/550E.txt)
F. [Graph Without Long Directed Paths(1700) (二分图解)](./code/550F.txt)
### Codeforces Round #578 (Div. 2) A. [Hotelier(800) ](./contest/578A.txt)
B. [Block Adventure(1200) (Greedy)](./contest/578B.txt)
C. [Round Corridor (1400) (Math) ](./contest/578C.txt)
D. [White Lines (1900) (Prefix sum+Implementation heavy) ](./contest/578D.txt)
E. [Compress Words (2000) (String + KMP) ](./contest/578E.txt)
### Codeforces Round #595 (Div. 3) A. [Yet Another Dividing into Teams (800) ](./contest/595A.txt)
B1. [Booking Exchange (Easy) (1000) ](./contest/595B1.txt)
B2. [Books Exchange (hard version) (1300) ](./contest/595B2.txt)
C1. [Good Number (Easy) (1300) ](./contest/595C1.txt)
C2. [Good Number (hard version) (1500) ](./contest/595C2.txt)
D1. [Too Many Segments (easy version) (1800) ](./contest/595D1.txt)
D2. [Too Many Segments (hard version) (1800) ](./contest/595D2.txt)
E. [By Elevator or Stairs? (1700) (DP) ](./contest/595E.txt)
F. [Maximum Weight Subset (2200) (Tree DP) ](./contest/595F.txt)
### Codeforces Round #605 (Div. 3) A. [Three Friends (900) ](./contest/605A.txt)
B. [Snow Walking Robot (1200)](./contest/605B.txt)
C. [ Yet Another Broken Keyboard (1200) Math+Com](./contest/605C.txt)
D. [Remove One Element (1500) DP](./contest/605D.txt)
E. [Nearest Opposite Parity (1900) 反向+多源dfs](./contest/605E.txt)
F. [Two Bracket Sequences (2200) dp](./contest/605F.txt)
### Codeforces Round #611 (Div. 3) A. [Minutes Before the New Year (800) ](./code/611A.txt)
B. [Candies Division (900)](./code/611B.txt)
C. [Friends and Gifts (1500) ](./code/611C.txt)
D. [Christmas Trees (1800) (BFS)](./code/611D.txt)
E. [New Year Parties (1800) (Greedy)](./code/611E.txt)
F. [DIY Garland (2200) (Greedy+Tree+Heap)](./code/611F.txt)
### Codeforces Round #617 (Div. 3) A. [ Array with Odd Sum (800) ](./contest/617A.txt)
B. [Food Buying (900) ](./contest/617B.txt)
C. [Yet Another Walking Robot (1500) ](./contest/617C.txt)
D. [Fight with Monsters (1500) (Math+Sort) ](./contest/617D.txt)
E1. [String Coloring (easy version) (1800) (Observation + Greedy) ](./contest/617E1.txt)
E2. [String Coloring (hard version) (2000) ](./contest/617E2.txt)
F. [Berland Beauty (2100) (dfs+tree+greedy+sort) ](./contest/617F.txt)
### Codeforces Round #624 (Div. 3) A. [Add Odd or Subtract Even (800) ](./code/624A.txt)
B. [WeirdSort (1200) ](./code/624A.txt)
F. [Moving Point (1900) Segment Tree](./code/624F.txt)
### Codeforces Round #640 (Div. 4) A. [Sum of Round Numbers (800) ](./code/640A.txt)
B. [Same Parity Summands (1200)](./code/640B.txt)
C. [K-th Not Divisible by n (1200)](./code/640C.txt)
D. [Alice, Bob and Candies (1300)](./code/640D.txt)
E. [Special Element (1500) (暴力)](./code/640E.txt)
F. [Binary String Reconstruction (1500) (暴力+观察)](./code/640F.txt)
G. [Special Permutation (1600) (观察+Implementation)](./code/640G.txt)
### Codeforces Round #661 (Div. 3) A. [Remove Smallest (800) ](./contest/661A.txt)
B. [Gifts Fixing (800)](./contest/661B.txt)
C. [Boat Competition (1200)](./contest/661C.txt)
D. [Binary String To Subsequences (1500)](./contest/661D.txt)
E1. [Weights Division (easy version) (2000)](./contest/661E1.txt)
E2. [Weights Division (Hard version) (2200)](./contest/661E2.txt)
### Codeforces Round #666 (Div. 2) A. [Juggling Letters (800) ](./code/666A.txt)
B. [Power Sequence (1500)](./code/666B.txt)
C. [Multiples of Length (1600) (贪心)](./code/666C.txt)
D. [Stoned Game (1800) (游戏)](./code/666D.txt)
E. [Monster Invader (2300) (复杂dp)](./code/666E.txt)
### Codeforces Round #667 (Div. 3) A. [Yet Another Two Integers Problem (800) ](./code/667A.txt)
B. [Minimum Product (1100)](./code/667B.txt)
C. [Yet Another Array Restoration (1200)](./code/667C.txt)
D. [Decrease the Sum of Digits (1500)](./code/667D.txt)
E. [Two Platforms (双指针+dp) (1800)](./code/667E.txt)
F. [Subsequences of Length Two (dp) (2100)](./code/667F.txt)
### Codeforces Round #668 (Div. 2) A. [Permutation Forgery (800)](./code/668A.txt)
B. [Array Cancellation (1000)](./code/668B.txt)
C. [Balanced Bitstring (1500)](./code/668C.txt)
D. [Tree Tag (1900)(game)](./code/668D.txt)
E. [Fixed Point Removal (2300)(线段树+二分法)](./code/668E.txt)
### Codeforces Round #669 (Div. 2) A. [Ahahahahahahahaha (1100)](./code/669A.txt)
B. [Big Vova (1300)](./code/669B.txt)
D. [Discrete Centrifugal Jumps (2200) (dp+stack)](./code/669D.txt)
### Codeforces Round #670 (Div. 2) A. [Subset Mex (900) ](./code/770A.txt)
B. [Maximum Product (1200)](./code/770B.txt)
C. [Link Cut Centroids (1700)](./code/770C.txt)
D. [Three Sequences (2200)](./code/770D.txt)
### Codeforces Round #672 (Div. 2) A. [ Cubes Sorting (Sort) (900) ](./contest/672A.txt)
B. [Rock and Lever (Bit) (1200)_](./contest/672B.txt)
C1. [Pokémon Army (easy version) (DP) (1300)](./contest/672C1.txt)
C2. [Pokémon Army (Hard version) (Greedy+Math) (2100)](./contest/672C2.txt)
D. [Rescue Nibel! (Combination) (1800)](./contest/672D.txt)
### Codeforces Round #673 (Div. 2) A. [ Copy-paste (900) ](./contest/673A.txt)
B. [ Two Arrays (1100) ](./contest/673B.txt)
C. [ K-Amazing Number (1500) ](./contest/673C.txt)
D. [ Make Them Equal (2000) Greedy ](./contest/673D.txt)
E. [ Xor Inverse (2000) Bit+Trie ](./contest/673E.txt)
### Codeforces Round #674 (Div. 3) A. [Floor Number (800) ](./contest/674A.txt)
B. [ Symmetric Matrix (900) ](./contest/674B.txt)
C. [ Increase and Copy (Binary Search+Math) (1100) ](./contest/674C.txt)
D. [ Non-zero Segments (1500)](./contest/674D.txt)
E. [ Rock, Paper, Scissors (1800) (MAX Flow)](./contest/674E.txt)
F. [ Number of Subsequences (2000) (Combanation+Math)](./contest/674F.txt)
### Codeforces Round #675 (Div. 2) A. [A - Fence (800)](./contest/675A.txt)
B. [ Nice Matrix (1300)](./contest/675B.txt)
C. [ Bargain (1700)](./contest/675C.txt)
D. [ Returning Home (2300) (Graph+Shortest Path) ](./contest/675D.txt)
### Codeforces Round #677 (Div. 3) A. [Boring Apartments (800) ](./contest/677A.txt)
B. [ Yet Another Bookshelf (800)](./contest/677B.txt)
C. [Dominant Piranha (900)](./contest/677C.txt)
D. [ Districts Connection (1200)](./contest/677D.txt)
E. [ Two Round Dances (1300)](./contest/677E.txt)
F. [ Zero Remainder Sum (2100)](./contest/677F.txt)
G. [Reducing Delivery Cost (2100) (Shortest Path)](./contest/677G.txt)
### Codeforces Round #683 (Div. 2) A. [Add Candies (800) ](./contest/683A.txt)
B. [ Numbers Box (800)](./contest/683B.txt)
C. [Knapsack (1300)](./contest/683C.txt)
D. [ Catching Cheaters (1800)](./contest/683D.txt)
E. [ Xor Tree(2100)](./contest/683E.txt)
### Educational Codeforces Round 83 (Div. 2) 1312B. [ Bogo Sort (DIV 2) (1000) ](./code/1312B.txt)
1312C. [ Adding Power (DIV 2) (1400) number theory](./code/1312C.txt)
1312D. [ Count the Arrays (DIV 2) (1700) 组合数学+number theory](./code/1312D.txt)
1312E. [ Array Shrinking (DIV 2) (2100) 区间dp](./code/1312E.txt)
### Educational Codeforces Round 93 (Div. 2) EDU93B. [ Bad Triangle (800) ](./contest/EDU93A.txt)
EDU93B. [ Substring Removal Game (800) ](./contest/EDU93B.txt)
EDU93C. [ Good Subarrays (1600) Math+prefixSum](./contest/EDU93C.txt)
EDU93D. [ Colored Rectangles (1800) DP](./contest/EDU93D.txt)
### Grakn Forces 2020 (Div. 2) GFA. [ Circle Coloring (800) ](./contest/GFA.txt)
GFB. [ Arrays Sum (1400) (Math) ](./contest/GFB.txt)
GFC. [ Discrete Acceleration (1500) Binary Search](./contest/GFC.txt)
GFD. [ Searchlights (2000)](./contest/GFD.txt)
GFE. [ Avoid Rainbow Cycles (2400) (Union Find)](./contest/GFE.txt)
GFF. [ Two Different (2300)(Bit Mask)](./contest/GFF.txt)
### Codeforces Global Round 11 GLOA. [ Avoiding Zero (900) ](./contest/GLOA.txt)
GLOB. [Chess Cheater (1400) (Sort+Greedy) ](./contest/GLOB.txt)
GLOC. [ The Hard Work of Paparazzi (2000) DP](./contest/GLOC.txt)
GLOD. [ Unshuffling a Deck (2000) sort](./contest/GLOD.txt)



### NYU Progteam Spring Break Practice 3/16/2020 https://vjudge.net/contest/362056

709A. [ Juicer (900) ](./code/709A.txt)
757A. [ Gotta Catch Em' All! (1000) ](./code/757A.txt)
514A. [ Chewbaсca and Number (1200) ](./code/514A.txt)
804B. [ Minimum number of steps (1400) (Math+Observation) ](./code/804B.txt)
687A. [ NP Hard Problem (1500) (二分图) ](./code/687A.txt)
782B. [ The Meeting Place Cannot Be Changed (1600) (Binary Search) ](./code/782B.txt)
484A. [ Bits (1700) (Bit+Greedy) ](./code/484A.txt)
778A. [ String Game (1700) (Binary Search) ](./code/778A.txt)
706D. [ Vasiliy's Multiset (1800) (Trie) ](./code/706D.txt)
721C. [ Journey (1800) (Graph) ](./code/721C.txt)
### NYU Progteam Friday Night 2/28/2019 (Greedy) https://vjudge.net/contest/359373
415D. [Mashmokh and ACM (1400) (dp) ](./code/415D.txt)
1148A. [ Another One Bites The Dust (800) ](./code/1148A.txt)
1158B. [ Game with Telephone Numbers (1200) (Greedy+Game) ](./code/1158B.txt)
383A. [ Milking cows (1600) ](./code/383A.txt)
1098A. [ Sum in the tree (1600) ](./code/1098A.txt)
# Algorithm Template [Suffix Array (后缀数组 (nlog^2 n))](./template/suffixArray.txt)
[Combination C(n,k) in mod ](./template/Combination.txt)
[Max Flow Dinic ](./template/maxflow.txt)
[Shortest Path ](./template/dijkstra.txt)
[2 SAT ](./code/776D.txt)
[ Kosaraju ](./template/Kosaraju.txt)
[ Fenwick Tree ](./template/BIT.txt)
[ Hopcroft (Solving Maximum matching Cardinality for Bipartile Graph) O(sqrt(n)*m)](./template/Hopcroft.txt)
[ Min Seg ](./template/seg1.txt)
[ Lazy Seg ](./template/Lazyseg1.txt)
[ Double Linkedlist ](./template/dd.txt)
# CodeForce 日常水题 ( 小于1500分 ) ### 800
38A.[Army (Implementation) ](./easy/38A.txt)
119A.[Epic Game (Implementation) ](./easy/119A.txt)
791A.[Bear and Big Brother (Implementation) ](./easy/791A.txt)
1178A.[Prime Minister (Greedy) ](./easy/1178A.txt)
1430B.[ Barrels (Sort) ](./easy/1430B.txt)
1445A.[Array Rearrangment (Greedy) ](./easy/1445A.txt)
### 900
1445B.[Eliminationt (Math) ](./easy/1445B.txt)
### 1000
29A.[Spit Problem ](./easy/29A.txt)
371A.[K-Periodic Array (Greedy) ](./easy/371A.txt)
### 1100
1038B.[Non-Coprime Partition (Math) ](./easy/1038B.txt)
### 1200
18C.[Stripe ](./easy/18C.txt)
23A.[You're Given a String... ](./easy/23A.txt)
### 1300
298A.[Snow Footprints (Greedy) ](./easy/298A.txt)
371B.[Fox Dividing Cheese (Math) ](./easy/371B.txt)
1038C.[Gambling (Game) ](./easy/1038C.txt)
1178B.[WOW Factor ](./easy/1178B.txt)
1178C.[Tiles ](./easy/1178C.txt)
1234B2.[Social Network (hard version) (LinkedList) ](./easy/1234B2.txt)
1285B.[Just Eat It! (prefix sum) ](./easy/1285B.txt)
1443B.[Saving the City (dp) ](./easy/1443B.txt)
### 1400
205B.[Little Elephant and Sorting ](./easy/205B.txt)
### 1500
53D.[Physical Education! (Sort) ](./easy/53D.txt)
1178D.[Prime Graph (Graph+Brute Force) ](./easy/1178D.txt)
# CodeForce 日常刷题 ### 1600
28B. [pSort (Union Find) ](./easy/28B.txt)
46C. [Hamsters and Tigers (Sliding Window) ](./cf/46C.txt)
371C. [Hamburgers (Binary Search + Math) ](./cf/371C.txt)
788A. [Functions again (Prefix) ](./cf/788A.txt)
1077D. [Cutting Out (Binary Search) ](./cf/1077D.txt)
### 1700
18B. [Platforms (Math) ](./easy/18B.txt)
29C. [Mail Stamps (Graph) ](./cf/29C.txt)
160C. [Find Pair (Math) ](./cf/160C.txt)
627A. [XOR Equation (Bit + DP) ](./cf/627A.txt)
1430D. [String Deletion (Greedy) ](./cf/1430D.txt)
### 1800
38E. [Let's Go Rolling! (DP) ](./cf/38E.txt)
371D. [Vessels (Ordered Map) ](./cf/371D.txt)
747D. [Winter Is Coming (Greedy+ Sort) ](./cf/747D.txt)
846C. [Four Segments (Prefix) ](./cf/846C.txt)
1077E. [Thematic Contests (Binary Search) ](./cf/1077E.txt)
1154E. [Two Teams (TreeMap+Fenwick) ](./cf/1154E.txt)
### 1900
14D. [Two Path ](./cf/14D.txt)
22D. [Segment (sort+Greedy) ](./cf/22D.txt)
19B. [Checkout Assistant (DP) ](./cf/19B.txt)
448C. [Painting Fence (Divide Conquer+Greedy) ](./cf/448C.txt)
1178E. [ Archaeology (Greedy) ](./cf/1178E.txt)
1430E. [String Reversal (BIT) ](./cf/1430E.txt)
### 2000
2B. [The least Round Way(DP) ](./cf/ .txt)
29D. [Ant on the Tree (Tree + LCA + Brute Force) ](./cf/29D.txt)
371E. [Subway Innovation (Prefix Sum+Math) ](./cf/371E.txt)
1438C. [Engineer Artem ](./cf/1438C.txt)
### 2100
791D. [ Bear and Tree Jumps (Tree DP) ](./cf/791D.txt)
### 2200
1178F1. [Short Colorful Strip (Interval DP) ](./cf/1178F1.txt)
# CodeForce 高分精算 23C. [Oranges and Apples (2500) Greedy ](./code/23C.txt)
324D. [Xenia and Dominoes (2100) DP+容斥原理 ](./code/324D.txt)
383C. [Propagating tree (DIV 1) (2000) 树状区间线段树 ](./code/383C.txt)
757C. [Felicity is Coming! (1900) ](./code/757C.txt)
776D. [The Door Problem (2000) 2 SAT + SCC ](./code/776D.txt)
803C. [Maximal GCD (1900) (Math) ](./code/803C.txt)
1031D. [Minimum Path (1900) (Do + Greedy) ](./code/1031D.txt)
1062D. [Fun with Integers (DIV 2) (1800) Graph ](./code/1062D.txt)
1392D. [Omkar and Bed Wars (Global) (1700) DP ](./code/1392D.txt)
1392F. [Omkar and Landslide (Global) (2400) Math+observation ](./code/1392F.txt)
1423B. [ Valuable Paper (1900) binary search+Bipartile Match+HopcroftKarp ](./code/1423B.txt)
1423J. [Bubble Cup hypothesis (2400) dp ](./code/1423J.txt)
1428E. [Carrots for Rabbits (2200) pq+greedy ](./code/1428E.txt)
1428F. [Fruit Sequence(2400) Math+Monoti Stack](./code/1428F.txt)
1428G1. [G1 - Lucky Numbers (Easy Version)(2900) 0-k knapsack to 0-1 knapsack](./code/1428G1.txt)
1435C. [Perform Easily (1900) Sort+Greedy+Sliding Window](./code/1435C.txt)
1435D. [Shurikens (1700) 贪心好题](./code/1435D.txt)
1435E. [Solo mid Oracle (2100) Math](./code/1435E.txt)
1436D. [Bandit in a City (1900) Tree+Greedy](./code/1436D.txt)
1436E. [Complicated Computations (2400) Segment Tree+Thinking](./code/1436E.txt)
1437C. [Chef Monocarp (1800) DP](./code/1437C.txt)
1437E. [Make It Increasing(2200) DP+LIS+Binary Search](./code/1437E.txt)
1437F. [Emotional Fishermen(2600) DP+Combination](./code/1437F.txt)
1442A. [Extreme Subtraction(1800) Greedy](./code/1442A.txt)
1442B. [Identify the Operations (1800) Math+Observation+Dara Structure](./code/1442B.txt)
311E. [Biologist (MIN CUT) (2300) ](./code/311E.txt)
# 参考 1. 最大权闭合子图 (https://www.cnblogs.com/TreeDream/p/5942354.html#_labelTop) (强顶)
证明 1: https://blog.csdn.net/yo_bc/article/details/75322370
证明 2: https://www.cnblogs.com/dilthey/p/7565206.html
2. 2-SAT Template:
https://github.com/JunBinLiang/Competitive-Coding/blob/master/2-SAT.cpp
https://cp-algorithms.com/graph/2SAT.html#toc-tgt-2