mirror of
https://gitee.com/coder-xiaomo/leetcode-problemset
synced 2025-10-22 21:46:46 +08:00
update
This commit is contained in:
@@ -12,7 +12,7 @@
|
||||
"translatedContent": "<p>字符串轮转。给定两个字符串<code>s1</code>和<code>s2</code>,请编写代码检查<code>s2</code>是否为<code>s1</code>旋转而成(比如,<code>waterbottle</code>是<code>erbottlewat</code>旋转后的字符串)。</p>\n\n<p><strong>示例1:</strong></p>\n\n<pre><strong> 输入</strong>:s1 = "waterbottle", s2 = "erbottlewat"\n<strong> 输出</strong>:True\n</pre>\n\n<p><strong>示例2:</strong></p>\n\n<pre><strong> 输入</strong>:s1 = "aa", s2 = "aba"\n<strong> 输出</strong>:False\n</pre>\n\n<ol>\n</ol>\n\n<p><strong>提示:</strong></p>\n\n<ol>\n\t<li>字符串长度在[0, 100000]范围内。</li>\n</ol>\n\n<p><strong>说明:</strong></p>\n\n<ol>\n\t<li>你能只调用一次检查子串的方法吗?</li>\n</ol>\n",
|
||||
"isPaidOnly": false,
|
||||
"difficulty": "Easy",
|
||||
"likes": 107,
|
||||
"likes": 116,
|
||||
"dislikes": 0,
|
||||
"isLiked": null,
|
||||
"similarQuestions": "[]",
|
||||
@@ -143,7 +143,7 @@
|
||||
"__typename": "CodeSnippetNode"
|
||||
}
|
||||
],
|
||||
"stats": "{\"totalAccepted\": \"41.3K\", \"totalSubmission\": \"75.3K\", \"totalAcceptedRaw\": 41335, \"totalSubmissionRaw\": 75298, \"acRate\": \"54.9%\"}",
|
||||
"stats": "{\"totalAccepted\": \"42.7K\", \"totalSubmission\": \"77.9K\", \"totalAcceptedRaw\": 42676, \"totalSubmissionRaw\": 77883, \"acRate\": \"54.8%\"}",
|
||||
"hints": [
|
||||
"如果一个字符串是另一个字符串的旋转,那么它就是在某个特定点上的旋转。例如,字符串waterbottle在3处的旋转意味着在第三个字符处切割waterbottle,并在左半部分(wat)之前放置右半部分(erbottle)。",
|
||||
"本质上,我们是在寻找是否有一种方式可以把第一个字符串分成两部分,即x和y,如此一来,第一个字符串就是xy,第二个字符串就是yx。例如,x = wat,y = erbottle。那么,第一个字符串xy = waterbottle,第二个字符串yx = erbottlewat。",
|
||||
|
Reference in New Issue
Block a user