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-05-02 23:44:12 +08:00
parent 7ea03594b3
commit 2a71c78585
4790 changed files with 11696 additions and 10944 deletions

View File

@@ -11,8 +11,8 @@
"translatedContent": null,
"isPaidOnly": false,
"difficulty": "Hard",
"likes": 474,
"dislikes": 15,
"likes": 491,
"dislikes": 16,
"isLiked": null,
"similarQuestions": "[{\"title\": \"Maximum XOR of Two Numbers in an Array\", \"titleSlug\": \"maximum-xor-of-two-numbers-in-an-array\", \"difficulty\": \"Medium\", \"translatedTitle\": null}, {\"title\": \"Maximum Genetic Difference Query\", \"titleSlug\": \"maximum-genetic-difference-query\", \"difficulty\": \"Hard\", \"translatedTitle\": null}]",
"exampleTestcases": "[0,1,2,3,4]\n[[3,1],[1,3],[5,6]]\n[5,2,4,6,6,3]\n[[12,4],[8,1],[6,3]]",
@@ -149,7 +149,7 @@
"__typename": "CodeSnippetNode"
}
],
"stats": "{\"totalAccepted\": \"8.4K\", \"totalSubmission\": \"19.4K\", \"totalAcceptedRaw\": 8362, \"totalSubmissionRaw\": 19398, \"acRate\": \"43.1%\"}",
"stats": "{\"totalAccepted\": \"8.7K\", \"totalSubmission\": \"20K\", \"totalAcceptedRaw\": 8661, \"totalSubmissionRaw\": 20027, \"acRate\": \"43.2%\"}",
"hints": [
"In problems involving bitwise operations, we often think on the bits level. In this problem, we can think that to maximize the result of an xor operation, we need to maximize the most significant bit, then the next one, and so on.",
"If there's some number in the array that is less than m and whose the most significant bit is different than that of x, then xoring with this number maximizes the most significant bit, so I know this bit in the answer is 1.",