1
0
mirror of https://gitee.com/coder-xiaomo/leetcode-problemset synced 2025-09-05 23:41:41 +08:00
Code Issues Projects Releases Wiki Activity GitHub Gitee
This commit is contained in:
2023-12-09 19:57:46 +08:00
parent 9bc4722a45
commit 3770b44d1e
4792 changed files with 10889 additions and 10886 deletions

View File

@@ -167,7 +167,7 @@
"__typename": "CodeSnippetNode"
}
],
"stats": "{\"totalAccepted\": \"29.7K\", \"totalSubmission\": \"85.5K\", \"totalAcceptedRaw\": 29700, \"totalSubmissionRaw\": 85471, \"acRate\": \"34.7%\"}",
"stats": "{\"totalAccepted\": \"29.7K\", \"totalSubmission\": \"85.5K\", \"totalAcceptedRaw\": 29704, \"totalSubmissionRaw\": 85479, \"acRate\": \"34.8%\"}",
"hints": [
"Make a new array A of +1/-1s corresponding to if hours[i] is > 8 or not. The goal is to find the longest subarray with positive sum.",
"Using prefix sums (PrefixSum[i+1] = A[0] + A[1] + ... + A[i]), you need to find for each j, the smallest i < j with PrefixSum[i] + 1 == PrefixSum[j]."