Here are my solutions for the Advent of Code event.
I had been missing various features of C#. At the same time, I found myself wondering how well I could handle situations where I had previously relied heavily on specific features of F#. So, this year, I decided to solve the AoC puzzles in C#.
Additionally, I’m looking forward to improving the parsing process. I plan to try out Superpower and invest in some extensions to achieve a concise syntax for some common patterns found in AoC inputs.
No longer happy with notebooks. Decided to sacrifice visualization at all and focus on a different thing: on optimizing the routine when solving puzzles, namely:
- Go to the site and download the input.
- Feed the input to the program.
- Copy the result to the clipboard.
- Paste it into the browser.
- Doh, wrong.
- Fix, compile, run, copy, paste.
- Doh, "You gave an answer too recently."
- Wait.
- Repeat.
This is how I came up with the idea of aoc-agent — a C# source generator that turns your library with actual algorithms into a self-validating, self-running console application that calculates and submits answers automatically.
Once again, F#. Found Farkle to be much better, still cumbersome and mind-numbing sometimes.
More F# and more visualization in a notebook. Try FParsec to parse input. Try lenses 😱.
Continue playing with F#. Discovered wonderful .NET Interactive notebooks. Invested into the presentation of the results: mermaid, plotly, canvas.
First time taking part in the event. As a C# developer who was reading a lot about F#, wanted to give it a try on "real" tasks. It showed to be quite suitable for many puzzles thanks to immutability and structural comparison out of the box.