This commit is contained in:
Unknown
2013-06-18 13:13:48 +08:00
parent f809ed7766
commit 0a8c1b30bf
3 changed files with 18 additions and 12 deletions

View File

@@ -36,7 +36,7 @@ Example 4.13 [presuffix.go](examples/chapter_4/presuffix.go)
strings.Contains(s, substr string) bool
##4.7.3 判断子字符串或字符在父字符串中出现的位置(索引)
##4.7.3 判断子字符串或字符在父字符串中出现的位置(索引)
`Index` 返回字符串 `str` 在字符串 `s` 中的索引(`str` 的第一个字符的索引),-1 表示字符串 `s` 不包含字符串 `str`
strings.Index(s, str string) int