1
0
mirror of https://gitee.com/coder-xiaomo/leetcode-problemset synced 2025-09-05 07:21:40 +08:00
Code Issues Projects Releases Wiki Activity GitHub Gitee
This commit is contained in:
2022-03-29 15:21:05 +08:00
parent b84ae535b7
commit e730aa6794
2244 changed files with 8703 additions and 59499 deletions

View File

@@ -11,8 +11,8 @@
"translatedContent": null,
"isPaidOnly": false,
"difficulty": "Medium",
"likes": 2038,
"dislikes": 192,
"likes": 2041,
"dislikes": 193,
"isLiked": null,
"similarQuestions": "[{\"title\": \"Subsequence of Size K With the Largest Even Sum\", \"titleSlug\": \"subsequence-of-size-k-with-the-largest-even-sum\", \"difficulty\": \"Medium\", \"translatedTitle\": null}]",
"exampleTestcases": "[1,15,7,9,2,5,10]\n3\n[1,4,1,5,7,3,6,1,9,9,3]\n4\n[1]\n1",
@@ -143,7 +143,7 @@
"__typename": "CodeSnippetNode"
}
],
"stats": "{\"totalAccepted\": \"46.3K\", \"totalSubmission\": \"66K\", \"totalAcceptedRaw\": 46343, \"totalSubmissionRaw\": 66029, \"acRate\": \"70.2%\"}",
"stats": "{\"totalAccepted\": \"46.4K\", \"totalSubmission\": \"66.1K\", \"totalAcceptedRaw\": 46407, \"totalSubmissionRaw\": 66113, \"acRate\": \"70.2%\"}",
"hints": [
"Think dynamic programming: dp[i] will be the answer for array A[0], ..., A[i-1].",
"For j = 1 .. k that keeps everything in bounds, dp[i] is the maximum of dp[i-j] + max(A[i-1], ..., A[i-j]) * j ."