AoC 2022 Day 16: Pressurinator

Source: Proboscidea Volcanium

Part 1

Given a graph of nodes, some of which have a pressure (per tick output value) and an agent that can move through the graph and activate specific nodes (so that they output their per tick value every future tick), what is the maximum total output possible in 30 steps?

read more...


Stateful Solvers and Iterators

Rust, yet again! Let’s take what we did last time with Solving Sudoku (again) and improve the code structure a bit more.

Goals:

  • Create a ‘Solver’ struct that can maintain state (such as how many states we’ve visited, how much time we’ve spent)
  • Track the above stats
  • Turn the ‘Solver’ into an iterator which will iterate through given solutions (a single call will give the first solution or you can run through the iterator to get all of them)

If you’d like to follow along, I’ve started uploading the code here: https://github.com/jpverkamp/rust-solvers

read more...


AoC 2021 Day 23: Amphipodinator

Source: Amphipod

Part 1: Given 4 rooms full of amphipods with various energy costs for movement (a=1, b=10, c=100, d=1000) and a hallway, how much energy does it take (at minimum) to sort the amphipods into their own rooms with the following conditions:

read more...


AoC 2021 Day 21: Dicinator

Source: Dirac Dice

Part 1: Play a simple game (describe below) with a loaded D100 (that always rolls 1, 2, 3, … 99, 100, 1, …). Return the score of the losing player times the number of times the die was rolled.

read more...