没有合适的资源?快使用搜索试试~ 我知道了~
扩展矩阵leetcode-Leetcode:力码
共251个文件
word search ii:2个
maximal square:2个
count triplets that can form two arrays of equal xor:2个
需积分: 5 0 下载量 176 浏览量
2021-07-01
03:12:09
上传
评论
收藏 168KB ZIP 举报
温馨提示
扩展矩阵leetcode 力码 *后续总和: 当所有元素都是正负时,我们可以使用前缀和+hashmap,这样更通用。 否则,我们可以使用滑动窗口并验证是否满足条件。 Solution 1: prefix sum + hashmap Solution 2: sliding window 频繁的铅: 用于存储元素对及其频率的hashmap 。 如果需要,使用priority_queue或bucket sorting对频率进行排序。 滑动窗口 K 移动 - 专注于大小为 n - k 的滑动窗口; 前缀和sw的差异 最小滑动窗口 => while (contition ok) 最大滑动窗口 => while (contition ko) 904. 水果入篮+++ 还原1248. 计算好子阵列的数量930. 带总和的二元子数组 窗外 最左边/最右边 二分查找 技巧:在这个问题中,您可以使用x * y = r => matrix[r/x][r%y]将二维数组转换为一维数组,我们可以使用二分搜索。 DP 矩阵 这个 pb 非常类似于 树 使用字符串或 long int 来表示树(long int 可
资源推荐
资源详情
资源评论
收起资源包目录
扩展矩阵leetcode-Leetcode:力码 (251个子文件)
542. 01 Matrix 1KB
456. 132 Pattern 2KB
15. 3Sum 1KB
16. 3Sum Closest 674B
18. 4Sum 2KB
211. Add and Search Word - Data structure design 2KB
2. Add Two Numbers 876B
863. All Nodes Distance K in Binary Tree 1KB
1344. Angle Between Hands of a Clock 298B
561. Array Partition I 1KB
1488. Avoid Flood in The City 1KB
110. Balanced Binary Tree 476B
682. Baseball Game 529B
121. Best Time to Buy and Sell Stock 328B
122. Best Time to Buy and Sell Stock II 326B
309. Best Time to Buy and Sell Stock with Cooldown 485B
173. Binary Search Tree Iterator 616B
94. Binary Tree Inorder Traversal 829B
102. Binary Tree Level Order Traversal 587B
107. Binary Tree Level Order Traversal II 746B
124. Binary Tree Maximum Path Sum 539B
257. Binary Tree Paths 665B
145. Binary Tree Postorder Traversal 1KB
144. Binary Tree Preorder Traversal 408B
199. Binary Tree Right Side View 516B
103. Binary Tree Zigzag Level Order Traversal 728B
803. Bricks Falling When Hit 4KB
1441. Build an Array With Stack Operations 475B
1375. Bulb Switcher III 301B
1529. Bulb Switcher IV 403B
605. Can Place Flowers 578B
787. Cheapest Flights Within K Stops 2KB
1461. Check If a String Contains All Binary Codes of Size K 924B
1455. Check If a Word Occurs As a Prefix of Any Word in a Sentence 1KB
1497. Check If Array Pairs Are Divisible by k 696B
70. Climbing Stairs 292B
133. Clone Graph 1KB
322. Coin Change 1KB
518. Coin Change 2 738B
39. Combination Sum 3KB
40. Combination Sum II 890B
1446. Consecutive Characters 279B
106. Construct Binary Tree from Inorder and Postorder Traversal 738B
105. Construct Binary Tree from Preorder and Inorder Traversal 745B
11. Container With Most Water 359B
108. Convert Sorted Array to Binary Search Tree 491B
222. Count Complete Tree Nodes 1KB
1399. Count Largest Group 1KB
1248. Count Number of Nice Subarrays 709B
1395. Count Number of Teams 478B
1277. Count Square Submatrices with All Ones 2KB
1504. Count Submatrices With All Ones 725B
1442. Count Triplets That Can Form Two Arrays of Equal XOR 1KB
1442. Count Triplets That Can Form Two Arrays of Equal XOR 1KB
739. Daily Temperatures 402B
394. Decode String 2KB
1472. Design Browser History 1KB
705. Design HashSet 4KB
1396. Design Underground System 1KB
1436. Destination City 1KB
1424. Diagonal Traverse II 1KB
575. Distribute Candies 272B
29. Divide Two Integers 1KB
174. Dungeon Game 594B
690. Employee Importance 1KB
150. Evaluate Reverse Polish Notation 2KB
1475. Final Prices With a Special Discount in a Shop 951B
438. Find All Anagrams in a String 1KB
1489. Find Critical and Pseudo-Critical Edges in Minimum Spanning Tree 2KB
652. Find Duplicate Subtrees 2KB
802. Find Eventual Safe States 1KB
295. Find Median from Data Stream 1KB
436. Find Right Interval 509B
1334. Find the City With the Smallest Number of Neighbors at a Threshold Distance 2KB
287. Find the Duplicate Number 2KB
1477. Find Two Non-overlapping Sub-arrays Each With Target Sum 1003B
430. Flatten a Multilevel Doubly Linked List 868B
114. Flatten Binary Tree to Linked List 475B
547. Friend Circles 2KB
22. Generate Parentheses 1KB
1627. Graph Connectivity With Threshold 1KB
1052. Grumpy Bookstore Owner 971B
274. H-Index 473B
275. H-Index II 3KB
337. House Robber III 596B
1410. HTML Entity Parser 2KB
661. Image Smoother 824B
380. Insert Delete GetRandom O(1) 2KB
147. Insertion Sort List 1KB
226. Invert Binary Tree 241B
785. Is Graph Bipartite? 3KB
463. Island Perimeter 1KB
230. Kth Smallest Element in a BST 363B
368. Largest Divisible Subset 3KB
84. Largest Rectangle in Histogram 1KB
84. Largest Rectangle in Histogram 632B
949. Largest Time for Given Digits 358B
1481. Least Number of Unique Integers after K Removals 709B
17. Letter Combinations of a Phone Number 2KB
17. Letter Combinations of a Phone Number 2KB
共 251 条
- 1
- 2
- 3
资源评论
weixin_38576045
- 粉丝: 6
- 资源: 881
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- GitBook 教授 Javascript 编程基础知识.zip
- Generation.org 开发的 JAVA 模块练习.zip
- FastDFS Java 客户端 SDK.zip
- etcd java 客户端.zip
- Esercizi di informatica!执行计划,metti alla prova!.zip
- Eloquent JavaScript 翻译 - 2ª edição .zip
- Eclipse Paho Java MQTT 客户端库 Paho 是一个 Eclipse IoT 项目 .zip
- disconf 的 Java 应用程序.zip
- cloud.google.com 上使用的 Java 和 Kotlin 代码示例.zip
- 未命名3(3).cpp
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功