azl397985856 / azl397985856/leetcode
【专题】 考虑每一项对结果到的贡献
Open
专题
- Dominant language
- JavaScript
- Stars
- 55.7k
- Forks
- 9.4k
- PR merge metrics
- No merged PRs in 30d
Description
常见的是给你一个数组,然后给你一个指标, 让你求这个指标的总和。
比如给你一个数组, 给你一个子数组最大值的指标, 让你求所有子数组最大值的总和。
我们可以考虑数组每一项装结果的贡献, 然后将其累加即可。
题目:
- https://leetcode.cn/problems/sum-of-subsequence-widths/
- https://leetcode.cn/problems/sum-of-subarray-ranges/
Contributor guide
Research direction
Start by reading the issue description and the two linked LeetCode problems: Sum of Subsequence Widths and Sum of Subarray Ranges. Determine where this topic belongs in the repository and document the contribution-based approach, with explanations or solutions for both referenced problems; done means the topic is complete and understandable to readers.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- documentation
- Issue type
- Documentation
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100