Advent of Code Day 13 - Distress Signal

Question Phew… This took a lot of googling to get right. Working with unstructured data in Go wasn’t as simple as I’m used to from JS. Having said that, I think the outcome is quite alright. The communication device is still acting up… We receive a distress signal but it seems like the packets are arriving out of order (our puzzle input). Packet pairs are separated by an empty line and the packet data is represented as integers and a list of integers....

December 19, 2022 · 8 min · 1541 words · Gal Elmalah

Advent of Code Day 12 - Hill Climbing Algorithm

Question We are stuck at a river between two mountains, our communication device can’t get a decent signal but don’t worry THIS IS FINE!! we can get through this if we only find a high enough place to get a signal out cool cool cool, no doubt no doubt no doubt stay optimistic, and don’t panic!!! The one thing going for us at the moment is that we have a height map from our device, we just need to get to the heighst point and send a distress signal...

December 14, 2022 · 11 min · 2163 words · Gal Elmalah

Advent of Code Day 10 - Cathode-Ray Tube

Question Crap seems like our rope physics knowledge from yesterday didn’t help and we wound up in the river… The elves are nowhere to be found and our communication system is spitting out weird signals and noise Luckily we can probably get this device up and running in no time we just need to make a drop-in replacement for the device’s video system. To do that we need to decode the instructions from the CPU and the register value first...

December 13, 2022 · 6 min · 1066 words · Gal Elmalah

Advent of Code Day 9 - Rope Bridge

Question AkA doing weird rope physics! You come across an old rope bridge and you are not sure it can hold your fat a** so you decide to model some rope physics to distract yourself (like that’s going to help…) Directly from AoC Consider a rope with a knot at each end; these knots mark the head and the tail of the rope. If the head moves far enough away from the tail, the tail is pulled toward the head....

December 10, 2022 · 5 min · 905 words · Gal Elmalah