Advent of code 2021 using Rust
See for inspiration:
Day | Rust | Python |
---|---|---|
1 | x | |
2 | x | |
3 | x | |
4 | x | |
5 | x | |
6 | x | |
7 | x | |
8 | x | |
9 | x | |
10 | x | |
11 | x | |
12 | x | |
13 | ||
14 | x | |
15 | x | |
16 | ||
17 | x | |
18 | ||
19 | x | |
20 | x | |
21 | x | |
22 | x |
Notes
Day 11
I reused my Vec[x][y] Option-padded grid logic from day 9. It would have been a good occasion to rewrite the grid logic as a HashMap.
Recursion FTW.
Day 22
I got inspired by this Python solution https://paste.ofcode.org/rLgHVR3Ux6pJntZUzX3MNp Quite happy with the use of Option pattern. Wrote my first custom struct with its own method. Really not happy about working with strings in Rust.