mirror of
https://gitee.com/coder-xiaomo/leetcode-problemset
synced 2025-10-23 05:48:57 +08:00
update
This commit is contained in:
@@ -12,7 +12,7 @@
|
||||
"translatedContent": "<p>下一个数。给定一个正整数,找出与其二进制表达式中1的个数相同且大小最接近的那两个数(一个略大,一个略小)。</p>\n\n<p> <strong>示例1:</strong></p>\n\n<pre>\n<strong> 输入</strong>:num = 2(或者0b10)\n<strong> 输出</strong>:[4, 1] 或者([0b100, 0b1])\n</pre>\n\n<p> <strong>示例2:</strong></p>\n\n<pre>\n<strong> 输入</strong>:num = 1\n<strong> 输出</strong>:[2, -1]\n</pre>\n\n<p> <strong>提示:</strong></p>\n\n<ol>\n<li><code>num</code>的范围在[1, 2147483647]之间;</li>\n<li>如果找不到前一个或者后一个满足条件的正数,那么输出 -1。</li>\n</ol>\n",
|
||||
"isPaidOnly": false,
|
||||
"difficulty": "Medium",
|
||||
"likes": 47,
|
||||
"likes": 48,
|
||||
"dislikes": 0,
|
||||
"isLiked": null,
|
||||
"similarQuestions": "[]",
|
||||
@@ -137,7 +137,7 @@
|
||||
"__typename": "CodeSnippetNode"
|
||||
}
|
||||
],
|
||||
"stats": "{\"totalAccepted\": \"6.5K\", \"totalSubmission\": \"17.7K\", \"totalAcceptedRaw\": 6517, \"totalSubmissionRaw\": 17708, \"acRate\": \"36.8%\"}",
|
||||
"stats": "{\"totalAccepted\": \"6.8K\", \"totalSubmission\": \"18.5K\", \"totalAcceptedRaw\": 6758, \"totalSubmissionRaw\": 18479, \"acRate\": \"36.6%\"}",
|
||||
"hints": [
|
||||
"下一步:从每个蛮力解法开始。",
|
||||
"下一个:想象一个二进制数,在整个数中分布一串1和0。假设你把一个1翻转成0,把一个0翻转成1。在什么情况下数会更大?在什么情况下数会更小?",
|
||||
|
Reference in New Issue
Block a user