advent-2021
aoc
Our great sponsors
advent-2021 | aoc | |
---|---|---|
19 | 22 | |
5 | 1 | |
- | - | |
6.8 | 9.0 | |
over 1 year ago | 4 months ago | |
Rust | Raku | |
- | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
advent-2021
- -🎄- 2021 Day 24 Solutions -🎄-
- -🎄- 2021 Day 23 Solutions -🎄-
-
-🎄- 2021 Day 22 Solutions -🎄-
Rust https://github.com/Crazytieguy/advent-2021/blob/master/src/bin/day22/main.rs Imagining the geometry of this was very tricky for me. For a while I contemplated if calculating the intersection of each pair of cuboids would give me enough information to know how many cubes are on at the end, and finally decided that I would also have to calculate the intersections of those and so on, so I gave up. Instead I decided that my state will be a vector of cuboids that are garuanteed to be non overlapping, and on each command I would subtract the current cuboid from each of these non overlapping cuboids (leaving 1 to 6 cuboids depending on intersection), and finally either add in the current cuboid (for on command) or leave it out (for off).
- -🎄- 2021 Day 21 Solutions -🎄-
- -🎄- 2021 Day 20 Solutions -🎄-
- -🎄- 2021 Day 19 Solutions -🎄-
- -🎄- 2021 Day 18 Solutions -🎄-
- -🎄- 2021 Day 16 Solutions -🎄-
- -🎄- 2021 Day 15 Solutions -🎄-
- -🎄- 2021 Day 14 Solutions -🎄-
aoc
- -❄️- 2023 Day 10 Solutions -❄️-
-
-❄️- 2023 Day 9 Solutions -❄️-
Full code at GitHub.
-
-❄️- 2023 Day 7 Solutions -❄️-
Edit: you don't need to determine the type of hand, but you can directly compare the card counts. Second version @GitHub.
-
-🎄- 2022 Day 13 Solutions -🎄-
New version @GitHub.
-
-🎄- 2022 Day 12 Solutions -🎄-
So, a new version with a lot less almost-duplicate code @GitHub.
- -🎄- 2022 Day 2 Solutions -🎄-
-
-🎄- 2022 Day 1 Solutions -🎄-
@GitHub
-
-🎄- 2021 Day 21 Solutions -🎄-
Completed part 2, see GitHub. I couldn't really use the same `DiracDice` class and simply use another `Die`, but had to create a separate `DiracDice2` class.Basically, just keep track of the possible universe state and their counts, and try all possible combinations of die rolls. Keep playing until all universes have a winner.
-
-🎄- 2021 Day 20 Solutions -🎄-
The rest is the same as my first attempt, but full code at GitHub.
-
-🎄- 2021 Day 18 Solutions -🎄-
I spent way too much time on this, but I completed my original attempt with the proper object model, see GitHub
What are some alternatives?
aoc2021 - Advent of Code 2021 - my answers
rockstar - The Rockstar programming language specification
advent-of-code-go - All 8 years of adventofcode.com solutions in Go/Golang; 2015 2016 2017 2018 2019 2020 2021 2022
AdventOfCode - My Advent of Code solutions. I also upload videos of my solves: https://www.youtube.com/channel/UCuWLIm0l4sDpEe28t41WITA
aoc2021 - Advent of Code 2021 on my homemade 16-bit CPU SCAMP
adventofcode - Advent of code solutions
deno_aoc - 🎄 Advent of code solutions written in TypeScript for Deno.
advent-of-code-2021 - zig solutions to advent of code 2021
AdventOfCode2021.jl - Advent of Code 2021 in Julia
Advent-of-Code - Advent of Code
advent-of-code
AdventOfCode2021FSharp - Solutions for Advent of Code 2021 in F#