update zh/String.md

This commit is contained in:
sunface
2022-03-08 21:52:35 +08:00
parent 52f771e681
commit f56fe4c040
3 changed files with 15 additions and 14 deletions

View File

@ -34,7 +34,6 @@ A `String` is stored as a vector of bytes (`Vec<u8>`), but guaranteed to always
```rust,editable
// FILL in the blanks
fn main() {
// get a slice of String with reference: String -> &str
let mut s = String::from("hello, world");
let slice1: &str = __; // in two ways