mirror of
https://gitee.com/coder-xiaomo/leetcode-problemset
synced 2025-09-05 07:21:40 +08:00
更新国内版力扣题目描述变更
This commit is contained in:
@@ -1,23 +1,23 @@
|
||||
<p>Given two strings, <code>s1</code> and <code>s2</code>, write code to check if <code>s2</code> is a rotation of <code>s1</code> (e.g.,"waterbottle" is a rotation of"erbottlewat"). Can you use only one call to the method that checks if one word is a substring of another?</p>
|
||||
|
||||
<p><strong>Example 1:</strong></p>
|
||||
|
||||
<pre>
|
||||
<strong>Input: </strong>s1 = <span id="example-input-1-1">"waterbottle"</span>, s2 = <span id="example-input-1-2">"</span>erbottlewat<span>"</span>
|
||||
<strong>Output: </strong><span id="example-output-1">True</span>
|
||||
</pre>
|
||||
|
||||
<p><strong>Example 2:</strong></p>
|
||||
|
||||
<pre>
|
||||
<strong>Input: </strong>s1 = "aa", s2 = "aba"
|
||||
<strong>Output: </strong>False
|
||||
</pre>
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong>Note:</strong></p>
|
||||
|
||||
<ol>
|
||||
<li><code><font face="monospace">0 <= s1.length, s2.length <= </font>100000</code></li>
|
||||
</ol>
|
||||
<p>Given two strings, <code>s1</code> and <code>s2</code>, write code to check if <code>s2</code> is a rotation of <code>s1</code> (e.g.,"waterbottle" is a rotation of"erbottlewat"). Can you use only one call to the method that checks if one word is a substring of another?</p>
|
||||
|
||||
|
||||
|
||||
<p><strong>Example 1:</strong></p>
|
||||
|
||||
|
||||
|
||||
<pre>
|
||||
|
||||
<strong>Input: </strong>s1 = <span id="example-input-1-1">"waterbottle"</span>, s2 = <span id="example-input-1-2">"</span>erbottlewat<span>"</span>
|
||||
|
||||
<strong>Output: </strong><span id="example-output-1">True</span>
|
||||
|
||||
</pre>
|
||||
|
||||
|
||||
|
||||
<p><strong>Example 2:</strong></p>
|
||||
|
||||
|
||||
|
||||
<pre>
|
||||
|
Reference in New Issue
Block a user