adventofcode
Advent of Code challenge solutions (by flwyd)
aoc2022 | adventofcode | |
---|---|---|
7 | 59 | |
3 | 6 | |
- | - | |
10.0 | 8.5 | |
over 1 year ago | 5 months ago | |
C++ | Julia | |
- | MIT License |
The number of mentions indicates the total number of mentions that we've tracked plus the number of user suggested alternatives.
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.
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.
aoc2022
Posts with mentions or reviews of aoc2022.
We have used some of these posts to build our list of alternatives
and similar projects. The last one was on 2022-12-11.
-
-๐- 2022 Day 12 Solutions -๐-
You can even take that one step further and calculate all paths to as in one go. My Python implementation of that runs in < 10 ms, C++ is at 20 ยตs.
-
-๐- 2022 Day 10 Solutions -๐-
Full code here.
-
-๐- 2022 Day 7 Solutions -๐-
Calculate part 1 in one pass and do a second only over the sizes for part 2 (because we know the size of / only at the very end). Hot runs take ~13 ยตs on a Core i9-12900K, including I/O. Code is here.
-
-๐- 2022 Day 6 Solutions -๐-
I coded it up in C++ here. Hot runs take ~5 ยตs on a Core i9-12900K (both parts, including I/O).
-
-๐- 2022 Day 4 Solutions -๐-
Most of the time is spent parsing, but this problem lends itself nicely to a SIMD formulation, which using vectorclass doesn't even require detailed knowledge of the intrinsics. Hot runs take ~14 ยตs on a Core i9-12900K, including I/O. Full code is (here)[https://github.com/ahans/aoc2022/blob/main/cpp/day04.cc], the interesting part is this, where we process 32 elements at once:
-
-๐- 2022 Day 1 Solutions -๐-
Inspired by somebody here solving it in CMake, I tried some Bazel misuse. Full solution here. When run, it looks like this:
adventofcode
Posts with mentions or reviews of adventofcode.
We have used some of these posts to build our list of alternatives
and similar projects. The last one was on 2023-12-09.
-
-โ๏ธ- 2023 Day 10 Solutions -โ๏ธ-
Code on GitHub is currently a mess.
-
[2023 Day 5] Exlplanation Like I'm 5
In the spirit of the Day 5 ALLEZ CUISINE! challenge to ELI5 (Explain Like I'm Five), here's a tasty explanation of how my algorithm works using only a large bucket of Red Vines and a knife. It says to use lined paper, but if you try this at home consider aligning things on a cutting board.
-
-โ๏ธ- 2023 Day 4 Solutions -โ๏ธ-
[Language: Jsonnet] (on GitHub)
- -๐- 2022 Day 25 Solutions -๐-
-
-๐- 2022 Day 24 Solutions -๐-
Elixir code, thoughts
-
-๐- 2022 Day 23 Solutions -๐-
Elixir 1554/1502 code, reflections
-
-๐- 2022 Day 21 Solutions -๐-
Elixir 2506/3402 (24 minutes, 2 hours), code, thoughts
-
-๐- 2022 Day 20 Solutions -๐-
Bonus solution in Go (golang) because I was confused about why my Elixir solution didn't work and decided to implement from scratch in case I'd done something dumb. The Go one also got the wrong answer, but took less than 100ms instead of a minute, so I could try out lots of tweaks that didn't change the answer.
-
-๐- 2022 Day 19 Solutions -๐-
Elixir 2031/2641 after 3.25/6.5 hours! Code on GitHub
-
-๐- 2022 Day 18 Solutions -๐-
I spent time this afternoon sprucing up my helpers for the iex REPL. I spent a bunch of time poking at things in IEx the last couple days and wanted to make sure I would minimize keystrokes if I needed to debug things on my phone while drunk. Turns out Thursday night > Friday night > Saturday night in terms of difficulty, so all those macros have so far saved me zero seconds :-)
What are some alternatives?
When comparing aoc2022 and adventofcode you can also consider the following projects:
AdventOfCode2022
adventofcode - Solutions for problems from AdventOfCode.com
advent-2022
adventofcode - Advent of Code solutions of 2015, 2016, 2017, 2018, 2019, 2020, 2021, 2022 and 2023 in Scala
aoc-2022 - Advent of Code 2022 in Rust
aoc2021 - Advent of Code 2021 - my answers
aoc - Advent of Code
AdventOfCode2021.jl - Advent of Code 2021 in Julia
advent-of-code
aoc2021 - Advent of Code 2021 on my homemade 16-bit CPU SCAMP
aocaml - AoC in OCaml, for maximum typing pleasure
rockstar - The Rockstar programming language specification