修改字符串 实控线strstr题目链接

This commit is contained in:
Allen
2022-09-08 08:30:42 +08:00
parent a5723e1858
commit e6f3beb3e6

View File

@ -9,7 +9,7 @@
# 28. 实现 strStr() # 28. 实现 strStr()
[力扣题目链接](https://leetcode.cn/problems/implement-strstr/) [力扣题目链接](https://leetcode.cn/problems/find-the-index-of-the-first-occurrence-in-a-string/)
实现 strStr() 函数。 实现 strStr() 函数。
@ -699,7 +699,7 @@ class Solution(object):
if haystack[i:i+n]==needle: if haystack[i:i+n]==needle:
return i return i
return -1 return -1
``` ```
```python ```python
// 方法一 // 方法一
class Solution: class Solution: