剑指offer第2版Python题解(更新中)

剑指offer和力扣

零、基础算法!

O(n^2)排序 https://blog.csdn.net/IOT_victor/article/details/91471881

归并 https://blog.csdn.net/IOT_victor/article/details/88365632

快排 https://blog.csdn.net/IOT_victor/article/details/91354621

堆排序 https://blog.csdn.net/IOT_victor/article/details/103604409

二分查找及其变体 https://blog.csdn.net/IOT_victor/article/details/91357208

Trie树 https://blog.csdn.net/IOT_victor/article/details/88936762

编辑距离 https://blog.csdn.net/IOT_victor/article/details/106670275

 一、数据结构类题目

 LinkedList

18.删除链表中重复的结点https://blog.csdn.net/IOT_victor/article/details/104475552

22.链表中倒数第k个结点https://blog.csdn.net/IOT_victor/article/details/104488173

23.链表中环的入口结点https://blog.csdn.net/IOT_victor/article/details/104582146 --------力扣-------------

力206. 反转链表 https://blog.csdn.net/IOT_victor/article/details/90605565

力24. 两两交换链表中的节点 https://blog.csdn.net/IOT_victor/article/details/105458212

148. 排序链表 https://blog.csdn.net/IOT_victor/article/details/106797213

归并排序-LeetCode23. 合并K个排序链表 https://blog.csdn.net/IOT_victor/article/details/106724729

 Stack & Queue & Heap

9.用两个栈实现队列https://blog.csdn.net/IOT_victor/article/details/104527495

9.两个队列实现栈https://blog.csdn.net/IOT_victor/article/details/104527495

31.栈的压入、弹出序列https://blog.csdn.net/IOT_victor/article/details/90707517

59.滑动窗口的最大值(双端队列)https://blog.csdn.net/IOT_victor/article/details/103929734

41.数据流中的中位数(Heap)https://blog.csdn.net/IOT_victor/article/details/103940622 --------力扣-------------

20. 有效的括号isValid(栈)https://blog.csdn.net/IOT_victor/article/details/105166364

Tree

7.重建二叉树https://blog.csdn.net/IOT_victor/article/details/104582658

8.二叉树的下一个结点https://blog.csdn.net/IOT_victor/article/details/104600275

26.树的子结构https://blog.csdn.net/IOT_victor/article/details/104596451

32.从上往下打印二叉树LeetCode102.层序遍历(双端队列,BFS)https://blog.csdn.net/IOT_victor/article/details/90718529

33.二叉搜索树的后序遍历序列https://blog.csdn.net/IOT_victor/article/details/90727569

37.序列化二叉树https://blog.csdn.net/IOT_victor/article/details/104601494

68.树中两个节点的最低公共祖先https://blog.csdn.net/IOT_victor/article/details/104622587

数组

3.数组中重复的数字(Array)https://blog.csdn.net/IOT_victor/article/details/104725037

39.数组中出现次数超过一半的数字(Array)https://blog.csdn.net/IOT_victor/article/details/91586129

21.调整数组顺序使奇数位于偶数前面(Array、双指针、稳定排序)https://blog.csdn.net/IOT_victor/article/details/104735419

57-1.和为S的两个数(双指针) https://blog.csdn.net/IOT_victor/article/details/103896707

57-2.和为S的连续正数序列(滑动窗口思想) https://blog.csdn.net/IOT_victor/article/details/103897041 --------力扣-------------

LeetCode54. 螺旋矩阵+59. 螺旋矩阵 II https://blog.csdn.net/IOT_victor/article/details/106795293

字符串

LeetCode14. 最长公共前缀 https://blog.csdn.net/IOT_victor/article/details/106415733 --------力扣-------------

 二、具体算法类题目

搜索算法

4.二维数组查找https://blog.csdn.net/IOT_victor/article/details/104642324

11.旋转数组的最小数字(二分查找)https://blog.csdn.net/IOT_victor/article/details/104362924

53.数字在排序数组中出现的次数(二分查找)https://blog.csdn.net/IOT_victor/article/details/104425653

排序 

51.数组中的逆序对(归并排序)https://blog.csdn.net/IOT_victor/article/details/104350702

力215. 数组中的第K个最大元素(快排、堆排序)https://blog.csdn.net/IOT_victor/article/details/88364912

全排列 38.字符串的排列https://blog.csdn.net/IOT_victor/article/details/90758921

动态规划 48.最长不含重复字符的子字符串

回溯 13.机器人的运动范围(DFS)

 

三、其他算法

3.1 Math、位运算

位运算 16.数值的整数次方(Math)https://blog.csdn.net/IOT_victor/article/details/104738503

44.数字序列中某一位的数字(Math)https://blog.csdn.net/IOT_victor/article/details/104736227

43.整数中1出现的次数(从1到n整数中1出现的次数)(Bit Manipulation)

67.把字符串转换成整数(Bit Manipulation) https://blog.csdn.net/IOT_victor/article/details/103939267 --------力扣-------------

位运算-LeetCode191. 位1的个数(剑指15:二进制中1的个数)https://blog.csdn.net/IOT_victor/article/details/106864049

3.2 贪心算法

贪心-LeetCode605. 种花问题 https://blog.csdn.net/IOT_victor/article/details/106723879

 

 

你可能感兴趣的:(刷题清单)