mirror of
https://gitee.com/coder-xiaomo/leetcode-problemset
synced 2025-09-04 23:11:41 +08:00
update
This commit is contained in:
@@ -12,7 +12,7 @@
|
||||
"translatedContent": "<p>设计一个算法,找出二叉搜索树中指定节点的“下一个”节点(也即中序后继)。</p>\n\n<p>如果指定节点没有对应的“下一个”节点,则返回<code>null</code>。</p>\n\n<p><strong>示例 1:</strong></p>\n\n<pre><strong>输入:</strong> root = <code>[2,1,3], p = 1\n\n 2\n / \\\n1 3\n</code>\n<strong>输出:</strong> 2</pre>\n\n<p><strong>示例 2:</strong></p>\n\n<pre><strong>输入:</strong> root = <code>[5,3,6,2,4,null,null,1], p = 6\n\n 5\n / \\\n 3 6\n / \\\n 2 4\n / \n1\n</code>\n<strong>输出:</strong> null</pre>\n",
|
||||
"isPaidOnly": false,
|
||||
"difficulty": "Medium",
|
||||
"likes": 93,
|
||||
"likes": 95,
|
||||
"dislikes": 0,
|
||||
"isLiked": null,
|
||||
"similarQuestions": "[]",
|
||||
@@ -101,7 +101,7 @@
|
||||
"__typename": "CodeSnippetNode"
|
||||
}
|
||||
],
|
||||
"stats": "{\"totalAccepted\": \"25.2K\", \"totalSubmission\": \"42.6K\", \"totalAcceptedRaw\": 25194, \"totalSubmissionRaw\": 42558, \"acRate\": \"59.2%\"}",
|
||||
"stats": "{\"totalAccepted\": \"26.1K\", \"totalSubmission\": \"44.2K\", \"totalAcceptedRaw\": 26102, \"totalSubmissionRaw\": 44182, \"acRate\": \"59.1%\"}",
|
||||
"hints": [
|
||||
"想想中序遍历是如何工作的,并尝试对其进行“逆向工程”。",
|
||||
"这只是逻辑方法中的一步:一个特定节点的后继节点是右子树的最左节点。如果没有右子树呢?"
|
||||
|
Reference in New Issue
Block a user