This commit is contained in:
2023-11-18 16:45:50 +01:00
parent 14d00e16d5
commit 3af5af2461
4 changed files with 32 additions and 0 deletions

10
2022/01/rust/main.rs Normal file
View File

@@ -0,0 +1,10 @@
fn main() {
// Part A
let result: u32 = include_str!("../input.txt")
.trim()
.split("\n\n")
.map(|x| x.lines().map(|x| x.parse::<u32>().unwrap()).sum())
.max()
.unwrap();
println!("A: {}", result);
}