version2
aoc
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.
version2
-
SIMD intrinsics and the possibility of a standard library solution
Vector class library - 938 GH stars
- Checking for the absence of a string, naive AVX-512 edition
-
-๐- 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:
- Significantly faster quicksort using SIMD
- Parsing JSON faster with Intel AVX-512
- What do you think is faster for batch-processing a lot of "double-type" arithmetic?
aoc
-
[2016 all days] [C] Advent of Code 2016 in C
Personally I just stick to raw arrays for most days, usually with static storage (so pre-allocated). Keeps things simple! Here's my repo.
-
-๐- 2022 Day 22 Solutions -๐-
- C -
-
[2022 Day 21 (Part 2)] Well, that's a new one for me...
Here's my solution. Sorry, I did go a bit overboard making it compact.
-
[2022 Day 18] I'm the only one?
That was one heck of a tough day but also very satisfying. I spent quite some time working out a 3D rectangle splitting/merging algorithm on paper and then I had to go and implement that in C. It turned out pretty clean and idiomatic, if I may say so!
-
[2022 Day 12] Flood fill
This was my first attempt (or at least in a very long time) at generating video. Here I'm generating raw RGB frames in memory and writing them to ffmpeg, which works well enough but it's a little primitive.
-
[2022] Writing C solutions the way Dennis intended it
At 50 year sold and very stable, C must be one of the easiest languages to get working on old machines. Required just some of the polyfills I wrote back in 2020.
-
-๐- 2022 Day 6 Solutions -๐-
My original solution checked every character against every other character, which performed perfectly fine even for 14 chars, but it felt wrong.
-
-๐- 2022 Day 4 Solutions -๐-
- C -
-
-๐- 2021 Day 25 Solutions -๐-
First a straightforward solution with a double buffer, later realised you could do it in-place by just holding onto one value per row/column.
-
-๐- 2021 Day 24 Solutions -๐-
First wrote a short AWK program to convert the input to C and play with it while running a hopeless brute force attempt.
What are some alternatives?
highway - Performance-portable, length-agnostic SIMD with runtime dispatch
advent-of-code-typescript-starter - Typescript template in Node.js for Advent of Code event
aoc22 - Advent of Code solutions for 2022 (in Python)
advent-of-code-jq - Solving Advent of Code with jq
advent2022
AdventOfCode - My Advent of Code solutions. I also upload videos of my solves: https://www.youtube.com/channel/UCuWLIm0l4sDpEe28t41WITA
adventOfCode2022
scamp-cpu - A homebrew 16-bit CPU with a homebrew Unix-like-ish operating system.
simde - Implementations of SIMD instruction sets for systems which don't natively support them.
AdventOfCode2021 - Solutions to all 25 AoC 2021 problems in Rust :crab: Less than 100 lines per day and under 1 second total execution time! :christmas_tree:
Day4 - My (messy) Python3 solution for day4's puzzle.
AlgorithmProblems - Solutions to Algorithm Problems :chart_with_upwards_trend: :neckbeard: