struct Person {
firstname: String,
lastname: String,
age: u8,
}
impl Person {
fn full_name(&self) -> String {
format!("{} {}", self.firstname, self.lastname)
}
}
Created
September 29, 2018 19:33
-
-
Save lalabuy948/053dc836e92c7b2f87835aa94773e960 to your computer and use it in GitHub Desktop.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment