michaelpanik / advent-of-code-2022

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Advent of Code 2022

https://adventofcode.com/2022

Day 6

Well I was feeling pretty good about my sub-20-minute time today, until I looked the leaderboards. I was right aroun 10 THOUSANDTH place. Rank 10798. Unreal. You nerds need something better to do with your time, idk.

But I digress.

Still nailed the problems and feeling good about it. I'll shoot for a better rank tommorrow night.

Day 5

A little embarassing, but I only today learned of the timed nature of the AoC challenge. I'm going to go for fast submission tonight. In order to help with that, I created a basic jest test, and I wrote a bash script to scaffold out the files for me. I could take it a step further and hit the page the second a new challenge is available, get the info, bring it in, etc., but that may be excessive.

Today was really hard, took a lot of time just parsing out the input properly. I also forget about the JS .reverse() function for arrays, and was trying to sort instead of reverse. What a pain.

Once again I set things up in a way where challenge 2 took only a very minor change and I nailed in on the first try. That's encouraging - I'm architecting solutions well, even if not cleverly.

Day 4

Well I just had to run my mouth. First day where I input an incorrect answer at first. BUT the solution to the second half was changing to function calls, Array.every to Array.some. JS Arrays are kind of magical, for all the language's flaws, and it really shines in moments like this.

Day 3

Eh, kind of sucks I think. But it works! And so far every time I actually run the code to get the final output, it's the right answer, first try! So it can't be all bad.

Day 2

Can't decide if I went too far today, might could have simplified. I actually started in one direction that sucked, but did get me the right answer in the first half. I scrapped that and started over to do the second half. This is a cautionary tale about setting up good data structures from the start.

Day 1

I haven't done AoC in a while. Time to brush up and do this thing in Typescript. No tricks, no hacks, just do the puzzles and publish them here.

About


Languages

Language:TypeScript 90.9%Language:Shell 7.6%Language:JavaScript 1.5%