This commit is contained in:
Alpha Pigger
2016-03-31 15:35:17 +08:00
parent 7c2305c375
commit a96a12322b

View File

@@ -62,7 +62,7 @@ strings.LastIndex(s, str string) int
如果 `ch` 是非 ASCII 编码的字符,建议使用以下函数来对字符进行定位:
```go
strings.IndexRune(s string, ch int) int
strings.IndexRune(s string, r rune) int
```
示例 4.14 [index_in_string.go](examples/chapter_4/index_in_string.go)