diff --git a/solutions/ownership/ownership.md b/solutions/ownership/ownership.md index c1429856c..78d196ab8 100644 --- a/solutions/ownership/ownership.md +++ b/solutions/ownership/ownership.md @@ -188,3 +188,13 @@ fn main() { println!("{:?}, {:?}, {:?}", s1, s2, t); // -> "hello", "world", ("hello", "world") } ``` +```rust +fn main() { + let t = (String::from("hello"), String::from("world")); + + // fill the blanks + let (s1, s2) = &t; + + println!("{:?}, {:?}, {:?}", s1, s2, t); // -> "hello", "world", ("hello", "world") +} +```