diff --git a/solutions/ownership/ownership.md b/solutions/ownership/ownership.md index 1237fc02..0d7e59bd 100644 --- a/solutions/ownership/ownership.md +++ b/solutions/ownership/ownership.md @@ -168,3 +168,14 @@ 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 (ref s1, ref s2) = t; + + println!("{:?}, {:?}, {:?}", s1, s2, t); // -> "hello", "world", ("hello", "world") +} +``` \ No newline at end of file