-
-
Save Gisleburt/d06f82cbd4b450b186050b8d8bcb47ea to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fn main() { | |
let daniel = User { | |
name: "Daniel".into(), | |
albums: vec![ | |
Album { | |
title: "Sgt. Pepper's Lonely Hearts Club Band".into(), | |
artist: "The Beatles".into(), | |
}, | |
Album { | |
title: "Dark Side of the Moon".into(), | |
artist: "Pink Floyd".into(), | |
}, | |
], | |
}; | |
println!("{}'s albums:", daniel.name); | |
println!("{}", daniel.borrow_albums()); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment