mirror of
https://gitee.com/coder-xiaomo/leetcode-problemset
synced 2025-09-04 06:51:41 +08:00
update
This commit is contained in:
@@ -11,8 +11,8 @@
|
||||
"translatedContent": null,
|
||||
"isPaidOnly": false,
|
||||
"difficulty": "Hard",
|
||||
"likes": 575,
|
||||
"dislikes": 46,
|
||||
"likes": 593,
|
||||
"dislikes": 49,
|
||||
"isLiked": null,
|
||||
"similarQuestions": "[{\"title\": \"Parallel Courses\", \"titleSlug\": \"parallel-courses\", \"difficulty\": \"Medium\", \"translatedTitle\": null}]",
|
||||
"exampleTestcases": "4\n[[2,1],[3,1],[1,4]]\n2\n5\n[[2,1],[3,1],[4,1],[1,5]]\n2\n11\n[]\n2",
|
||||
@@ -155,7 +155,7 @@
|
||||
"__typename": "CodeSnippetNode"
|
||||
}
|
||||
],
|
||||
"stats": "{\"totalAccepted\": \"10.4K\", \"totalSubmission\": \"32.9K\", \"totalAcceptedRaw\": 10425, \"totalSubmissionRaw\": 32877, \"acRate\": \"31.7%\"}",
|
||||
"stats": "{\"totalAccepted\": \"10.7K\", \"totalSubmission\": \"33.8K\", \"totalAcceptedRaw\": 10709, \"totalSubmissionRaw\": 33787, \"acRate\": \"31.7%\"}",
|
||||
"hints": [
|
||||
"Use backtracking with states (bitmask, degrees) where bitmask represents the set of courses, if the ith bit is 1 then the ith course was taken, otherwise, you can take the ith course. Degrees represent the degree for each course (nodes in the graph).",
|
||||
"Note that you can only take nodes (courses) with degree = 0 and it is optimal at every step in the backtracking take the maximum number of courses limited by k."
|
||||
|
Reference in New Issue
Block a user