fix a typo

fix a typo
This commit is contained in:
tanliwei 2022-02-09 14:56:11 +08:00 committed by GitHub
parent 7e44e87a77
commit af1768d9f2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -20,7 +20,7 @@ fn main() {
let word = first_word(&my_string[0..6]);
let word = first_word(&my_string[..]);
// `first_word` 也适用于 `String` 的引用,
// 这等价于个 `String` 的 slice
// 这等价于个 `String` 的 slice
let word = first_word(&my_string);
let my_string_literal = "hello world";