mirror of
https://github.com/sunface/rust-by-practice.git
synced 2025-06-26 14:09:41 +00:00
update zh/String.md
This commit is contained in:
@ -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
|
||||
|
Reference in New Issue
Block a user