1. 项目说明 2. 题目列表 3. 数据结构分类 3.1 数组与矩阵 3.2 链表 3.3 字符串 3.4 栈和队列 3.5 树 3.6 图 3.7 位运算 3.8 哈希表 4. 解法分类 4.1 双指针 4.2 排序 4.3 二分查找 4.4 贪心算法 4.5 分治 4.6 搜索 4.7 动态规划 4.8 数学 1. 项目说明 C++代码工程使用 CMake 创建并测试。 测试依赖: Catch2 2. 题目列表 # Title Solution Difficulty Note 0001 Two Sum C++ Easy note 0007 Reverse Integer C++ Easy 0008 String to Integer C++ Medium 0019 Remove Nth Node From End of List C++ Medium 0026 Remove Duplicates from Sorted Array C++ Easy 0036 Valid Sudoku C++ Medium 0048 Rotate Image C++ Medium 0066 Plus One C++ Easy 0094 Binary Tree Inorder Traversal C++ Medium 0101 Symmetric Tree C++ Easy 0102 Binary Tree Level Order Traversal C++ Medium 0104 Maximum Depth of Binary Tree C++ Easy 0105 Construct Binary Tree from Preorder and Inorder Traversal C++ Medium 0106 Construct Binary Tree from Inorder and Postorder Traversal C++ Medium 0112 Path Sum C++ Easy 0116 Populating Next Right Pointers in Each Node C++ Medium 0122 Best Time to Buy and Sell Stock II C++ Easy 0125 Valid Palindrome C++ Easy 0136 Single Number C++ Easy 0141 Linked List Cycle C++ Easy 0142 Linked List Cycle II C++ Medium 0144 Binary Tree Preorder Traversal C++ Medium 0145 Binary Tree Postorder Traversal C++ Hard 0160 Intersection of Two Linked Lists C++ Easy 0167 note 0189 Rotate Array C++ Easy 0206 Reverse Linked List C++ Easy 0217 Contains Duplicate C++ Easy 0283 Move Zeroes C++ Easy 0328 Odd Even Linked List C++ Medium 0344 Reverse String C++ Easy 0350 Intersection of Two Arrays II C++ Easy 0707 Design Linked List C++ Easy Note 0724 Find Pivot Index C++ Easy 0747 Largest Number At Least Twice of Others C++ Easy 1114 Print in Order C++ Easy 1115 Print FooBar Alternately C++ Medium 1116 Print Zero Even Odd C++ Medium 1117 Building H2O C++ Hard 3. 数据结构分类 3.1 数组与矩阵 3.2 链表 3.3 字符串 3.4 栈和队列 3.5 树 3.6 图 3.7 位运算 3.8 哈希表 4. 解法分类 4.1 双指针 4.2 排序 4.3 二分查找 4.4 贪心算法 4.5 分治 4.6 搜索 4.7 动态规划 4.8 数学