【leetcode】高頻題目整理_深度優先遍歷篇( High Frequency Problems, Depth-first Search )

截止至今LeetCode題目總量已經有1582題,估計將來每年平均增長300題左右,大部分人肯定是刷不完的,所以得有選擇地刷LeetCode。

一種公認的刷題策略是按類別刷題,可是每個類別也有許多題,在有限的時間裏到底該刷哪些題呢?個人根據LeetCode官方給出的每個題目的出現頻率,整理並收錄了每個類別裏高頻出現的題目,對於官方統計頻率太低的題目,不予收錄,最終得到了這個高頻題目表格。

例如,對於下圖中題號#275#270的題目將被收錄,並且#275出現頻率大於#270;而對於題號#1011#1182的題目,因爲出現頻率太低,將不被收錄:在這裏插入圖片描述

擼起鍵盤加油幹!祝大家成功上岸!整理不易,點個贊吧!


深度優先遍歷篇-69題(Depth-first Search, 69 problems)

2020/03/29更新: 之前有些題目的跳轉鏈接不對,現在已經改過來了
數據日期: 2020/03/26 (此時LeetCode題目數量:1582)
數據來源: LeetCode官方,將不同類別的題目按照官方給的出現頻率(Frequency)降序排列,取有頻率統計的題。

排序 題號 題目 通過率 難度
1 #679 24 Game 0.424 困難
2 #104 Maximum Depth of Binary Tree 0.726 簡單
3 #108 Convert Sorted Array to Binary Search Tree 0.699 簡單
4 #546 Remove Boxes 0.496 困難
5 #394 Decode String 0.493 中等
6 #114 Flatten Binary Tree to Linked List 0.681 中等
7 #105 Construct Binary Tree from Preorder and Inorder Traversal 0.646 中等
8 #488 Zuma Game 0.406 困難
9 #101 Symmetric Tree 0.506 簡單
10 #109 Convert Sorted List to Binary Search Tree 0.711 中等
11 #542 01 Matrix 0.381 中等
12 #199 Binary Tree Right Side View 0.639 中等
13 #491 Increasing Subsequences 0.463 中等
14 #200 Number of Islands 0.478 中等
15 #257 Binary Tree Paths 0.63 簡單
16 #301 Remove Invalid Parentheses 0.452 困難
17 #124 Binary Tree Maximum Path Sum 0.397 困難
18 #695 Max Area of Island 0.632 中等
19 #112 Path Sum 0.493 簡單
20 #638 Shopping Offers 0.571 中等
21 #664 Strange Printer 0.43 困難
22 #690 Employee Importance 0.575 簡單
23 #207 Course Schedule 0.496 中等
24 #100 Same Tree 0.569 簡單
25 #133 Clone Graph 0.525 中等
26 #111 Minimum Depth of Binary Tree 0.418 簡單
27 #329 Longest Increasing Path in a Matrix 0.401 困難
28 #130 Surrounded Regions 0.398 中等
29 #337 House Robber III 0.564 中等
30 #110 Balanced Binary Tree 0.509 簡單
31 #99 Recover Binary Search Tree 0.559 困難
32 #863 All Nodes Distance K in Binary Tree 0.477 中等
33 #332 Reconstruct Itinerary 0.363 中等
34 #515 Find Largest Value in Each Tree Row 0.585 中等
35 #547 Friend Circles 0.557 中等
36 #733 Flood Fill 0.53 簡單
37 #513 Find Bottom Left Tree Value 0.688 中等
38 #721 Accounts Merge 0.323 中等
39 #113 Path Sum II 0.589 中等
40 #106 Construct Binary Tree from Inorder and Postorder Traversal 0.675 中等
41 #514 Freedom Trail 0.38 困難
42 #529 Minesweeper 0.594 中等
43 #473 Matchsticks to Square 0.371 中等
44 #417 Pacific Atlantic Water Flow 0.408 中等
45 #494 Target Sum 0.441 中等
46 #129 Sum Root to Leaf Numbers 0.624 中等
47 #98 Validate Binary Search Tree 0.295 中等
48 #971 Flip Binary Tree To Match Preorder Traversal 0.43 中等
49 #210 Course Schedule II 0.465 中等
50 #576 Out of Boundary Paths 0.36 中等
51 #711 Number of Distinct Islands II 0.561 困難
52 #685 Redundant Connection II 0.335 困難
53 #472 Concatenated Words 0.438 困難
54 #1254 Number of Closed Islands 0.589 中等
55 #339 Nested List Weight Sum 0.777 簡單
56 #116 Populating Next Right Pointers in Each Node 0.564 中等
57 #439 Ternary Expression Parser 0.548 中等
58 #505 The Maze II 0.439 中等
59 #490 The Maze 0.442 中等
60 #117 Populating Next Right Pointers in Each Node II 0.464 中等
61 #694 Number of Distinct Islands 0.457 中等
62 #323 Number of Connected Components in an Undirected Graph 0.553 中等
63 #499 The Maze III 0.303 困難
64 #261 Graph Valid Tree 0.449 中等
65 #737 Sentence Similarity II 0.41 中等
66 #533 Lonely Pixel II 0.454 中等
67 #366 Find Leaves of Binary Tree 0.73 中等
68 #364 Nested List Weight Sum II 0.687 中等
69 #531 Lonely Pixel I 0.651 中等

相關/參考鏈接

leetcode-cn
leetcode

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章