Advent of Code 2021: 25x2 coding puzzles for December

It’s that time again, actually I’m about two days late.

If you’re not familiar, here’s a quick synopsis, courtesy of @gadgetgirl:

More information can be found on their website.

This isn’t the first time we’ve done this, here are links to the previous years’ discussions:

I’ve set up a private leaderboard. You can be a member in more than one, so don’t worry about that, but be aware that your name will appear as it does on the Advent of Code website. In other words, it could show your real name. I login via GitHub for this group, and via Google for work. If you want to join this leaderboard, the code is 256706-bb2717ff. If you’ve joined in a previous year, you don’t have to join again.

I’ll tag the others that were active last year:

Please feel free to include anyone else you think my be interested.

I set up a gitlab repo in 2018, and I neglected to upload any code to it last year, but I will try to do a better job of it this year. Also, I renamed the repo some time ago, but apparently you can’t update the canonical URL…

I did 2018’s puzzles in Python (and C#?) and I did 2019’s puzzles in C#. I’m pretty sure I only did 2020 in Python, but who can remember any more. I’d love to do them in more than one language, but time is never on my side, so Python it is again. I actually prefer C# for TDD for a handful of reasons, but Python is easier to deal with for almost everything else. I’ve used PyCharm in the past, but switched over to Visual Studio Code since last year, and I’d recommend it for anyone who hasn’t tried it yet.

Feel free to post questions and solutions in this thread, but please be kind and blur out any spoilers.

2 Likes

Oh, dear. I’d been thinking about this lately, but my mind hadn’t put 2 + 2 together to realize it was already time for it to start up again. Is it really a whole year since the last one?

Time’s been rather tight lately, but I’ll have to see if I can get further on this one than the last.

2 Likes

Same here. I’ve also been doing a lot of coding in my off hours on a personal project I’m pretty excited about so it’s gonna be hard to balance but I’m going to try to participate this year.

I used VS code for a bit for perl coding, and it went decently. Mainly had two issues that I haven’t completely ironed out:

  • I found a perl addon for VS code that also allowed you to run the code in the IDE with breakpoints/etc, but that addon went defunct months later. Haven’t found a good replacement yet.
  • I typically do my coding, compiling, and change management in a cygwin environment, and linking VS code to perl or git within that environment is nontrivial. I got git working, but it required some hacky .bat programming to make things work.

Granted, I’m a bit of an edge case there. :wink:

I can’t help you there. What little perl I wrote was long ago and very rudimentary.

Consider Windows Subsystem for Linux. I think it technically runs a VM under the hood, but integrates really seamlessly with Windows and Visual Studio Code, and is well suited for a development environment. I’d recommend WSL2 unless you have some sort of specific need for functionality provided by WSL1.

2 Likes

Oh, didn’t expect it. Like I said, edge case. :smiley:

Hrm, I’ve considered looking into it a few times, but haven’t gotten to the point of digging in to see what kind of trouble I can get into with it. One thing I do like with cygwin, though, is that I can make it portable and take it with me on a flash drive… not sure WSL will let me do anything similar.

2 Likes