use std::fmt;
fn main() {
let tatesa = Rustacean{name: "Tatesa", pronouns: Pronouns::SheHer, distro: "NixOS"};
println!("{tatesa}");
}
#[allow(dead_code)]
struct Rustacean<'a> {
name: &'a str,
pronouns: Pronouns<'a>,
distro: &'a str,
}
#[allow(dead_code)]
enum Pronouns<'a> {
HeHim,
SheHer,
TheyThem,
ItIts,
Other(&'a str),
}
impl fmt::Display for Rustacean<'_> {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
write!(f, "Hi! I am {}, and use {} BTW!", self.name, self.distro)
}
}
Rust is the language of future.
- Slovakia
-
09:34
(UTC +02:00) - https://en.pronouns.page/@jantatesa
Pinned Loading
-
-
-
obsidian-open-random-broken-link
obsidian-open-random-broken-link PublicExpand your knowledge by opening random broken links
TypeScript
-
Something went wrong, please refresh the page to try again.
If the problem persists, check the GitHub status page or contact support.
If the problem persists, check the GitHub status page or contact support.