经典算法真题演练【进阶】

 

分类

题⽬

答案链接

 

 

 

模拟

134. 加油站

https://leetcode-cn.com/problems/gas-station/

146. LRU缓存机制

https://leetcode-cn.com/problems/lru-cache/

289. 生命游戏

https://leetcode-cn.com/problems/game-of-life/

371. 两整数之和

https://leetcode-cn.com/problems/sum-of-two-i ntegers/

412. Fizz Buzz

https://leetcode-cn.com/problems/fizz-buzz/

202. 快乐数

https://leetcode-cn.com/problems/happy-numbe r/

 

分类

题⽬

答案链接

 

 

 

 

 

 

数组

152. 乘积最大子序列

https://leetcode-cn.com/problems/maxim um-product-subarray/

169. 求众数

https://leetcode-cn.com/problems/majori ty-element/

189. 旋转数组

https://leetcode-cn.com/problems/rotate

-array/

217. 存在重复元素

https://leetcode-cn.com/problems/contai ns-duplicate/

283. 移动零

https://leetcode-cn.com/problems/move

-zeroes/

384. 打乱数组

https://leetcode-cn.com/problems/shuffl e-an-array/

350. 两个数组的交集 II

https://leetcode-cn.com/problems/inters ection-of-two-arrays-ii/

334. 递增的三元子序列

https://leetcode-cn.com/problems/increa sing-triplet-subsequence/

240. 搜索二维矩阵 II

https://leetcode-cn.com/problems/search

-a-2d-matrix-ii/

238. 除自身以外数组的乘积

https://leetcode-cn.com/problems/produ ct-of-array-except-self/

 

分类

题⽬

答案链接

 

 

 

 

 

链表

138. 复制带随机指针的链表

https://leetcode-cn.com/problems/copy-lis t-with-random-pointer/

141. 环形链表

https://leetcode-cn.com/problems/linked-li st-cycle/

148. 排序链表

https://leetcode-cn.com/problems/sort-lis t/

160. 相交链表

https://leetcode-cn.com/problems/intersec t ion-of-two-linked-lists/

206. 反转链表

https://leetcode-cn.com/problems/reverse- linked-list/

234. 回文链表

https://leetcode-cn.com/problems/palindro me-linked-list/

237. 删除链表中的节点

https://leetcode-cn.com/problems/delete- node-in-a-linked-list/

328. 奇偶链表

https://leetcode-cn.com/problems/odd-eve n-linked-list/

 

分类

题⽬

答案链接

 

 

 

155. 最小栈

https://leetcode-cn.com/problems/min-st ack/

215. 数组中的第K个最大元素

https://leetcode-cn.com/problems/kth-lar gest-element-in-an-array/

295. 数据流的中位数

https://leetcode-cn.com/problems/find-m edian-from-data-stream/

378. 有序矩阵中第K小的元素

https://leetcode-cn.com/problems/kth-s mallest-element-in-a-sorted-matrix/

347. 前K个高频元素

https://leetcode-cn.com/problems/top-k- frequent-elements/

 

分类

题⽬

答案链接

 

 

150. 逆波兰表达式求值

https://leetcode-cn.com/problems/evaluate

-reverse-polish-notation/

227. 基本计算器 II

https://leetcode-cn.com/problems/basic-cal culator-ii/

341. 扁平化嵌套列表迭代器

https://leetcode-cn.com/problems/flatten- nested-list-iterator/

 

分类

题⽬

答案链接

 

哈希 / Map

171. Excel表列序号

https://leetcode-cn.com/problems/excel-sheet-c olumn-number/

454. 四数相加 II

https://leetcode-cn.com/problems/4sum-ii/

380. 常数时间插入、删除和获取随机元素

https://leetcode-cn.com/problems/insert-delete- getrandom-o1/

 

分类

题⽬

答案链接

队列

239. 滑动窗口最大值

https://leetcode-cn.com/problems/sliding-window

-maximum/

 

分类

题⽬

答案链接

 

 

230. 二叉搜索树中第K小的元素

https://leetcode-cn.com/problems/kth-s mallest-element-in-a-bst/

236. 二叉树的最近公共祖先

https://leetcode-cn.com/problems/lowes t-common-ancestor-of-a-binary-tree/

297. 二叉树的序列化与反序列化

https://leetcode-cn.com/problems/seriali ze-and-deserialize-binary-tree/

 

分类

题⽬

答案链接

线段树

218. 天际线问题

https://leetcode-cn.com/problems/the-skyline-proble m/

 

分类

题⽬

答案链接

排序

179. 最大数

https://leetcode-cn.com/problems/largest-number/

324. 摆动排序 II

https://leetcode-cn.com/problems/wiggle-sort-ii/

 

分类

题⽬

答案链接

滑动窗口

395. 至少有K个重复字符的最长子串

https://leetcode-cn.com/problems/longest-substring

-with-at-least-k-repeating-characters/

 

分类

题⽬

答案链接

动态规划

124. 二叉树中的最大路径和

https://leetcode-cn.com/problems/binary-tre e-maximum-path-sum/

 

 

 

128. 最长连续序列

https://leetcode-cn.com/problems/longest-c onsecutive-sequence/

198. 打家劫舍

https://leetcode-cn.com/problems/house-ro bber/

279. 完全平方数

https://leetcode-cn.com/problems/perfect-s quares/

300. 最长上升子序列

https://leetcode-cn.com/problems/longest-i ncreasing-subsequence/

322. 零钱兑换

https://leetcode-cn.com/problems/coin-chan ge/

329. 矩阵中的最长递增路径

https://leetcode-cn.com/problems/longest-i ncreasing-path-in-a-matrix/

 

 

分类

题⽬

答案链接

 

图论

127. 单词接龙

https://leetcode-cn.com/problems/word-ladder/

200. 岛屿的个数

https://leetcode-cn.com/problems/number-of-islands/

207. 课程表

https://leetcode-cn.com/problems/course-schedule/

210. 课程表 II

https://leetcode-cn.com/problems/course-schedule-ii/

 

 

分类

题⽬

答案链接

 

 

 

 

 

 

数学 & 位运算

136. 只出现一次的数字

https://leetcode-cn.com/problems/single-nu mber/

149. 直线上最多的点数

https://leetcode-cn.com/problems/max-poin ts-on-a-line/

166. 分数到小数

https://leetcode-cn.com/problems/fraction-t o-recurring-decimal/

172. 阶乘后的零

https://leetcode-cn.com/problems/factorial- trailing-zeroes/

190. 颠倒二进制位

https://leetcode-cn.com/problems/reverse-bi ts/

191. 位1的个数

https://leetcode-cn.com/problems/number-o f-1-bits/

204. 计数质数

https://leetcode-cn.com/problems/count-pri mes/

268. 缺失数字

https://leetcode-cn.com/problems/missing-n umber/

326. 3的幂

https://leetcode-cn.com/problems/power-of

-three/

 

 

分类

题⽬

答案链接

字符串

125. 验证回文串

https://leetcode-cn.com/problems/valid-palind rome/

131. 分割回文串

https://leetcode-cn.com/problems/palindrome

 

 

-partitioning/

139. 单词拆分

https://leetcode-cn.com/problems/word-brea k/

140. 单词拆分 II

https://leetcode-cn.com/problems/word-break

-ii/

208. 实现 Trie (前缀树)

https://leetcode-cn.com/problems/implement- trie-prefix-tree/

212. 单词搜索 II

https://leetcode-cn.com/problems/word-searc h-ii/

242. 有效的字母异位词

https://leetcode-cn.com/problems/valid-anagr am/

387. 字符串中的第一个唯一字符

https://leetcode-cn.com/problems/first-unique

-character-in-a-string/

344. 反转字符串

https://leetcode-cn.com/problems/reverse-stri ng/

 

你可能感兴趣的:(算法,算法,数据结构,LeetCode,面试)