1
0

Initial commit

This commit is contained in:
2025-12-16 20:38:14 +00:00
commit 66ef613a6d
221 changed files with 8079 additions and 0 deletions

View File

@@ -0,0 +1,16 @@
// Lifetimes are also needed when structs hold references.
// TODO: Fix the compiler errors about the struct.
struct Book<'a> {
author: &'a str,
title: &'a str,
}
fn main() {
let book = Book {
author: "George Orwell",
title: "1984",
};
println!("{} by {}", book.title, book.author);
}