2025-advent-of-code
denis schluppeck
Following along with the Advent of Code 2025 in Matlab.
General idea is to have a folder per day with solutions in Matlab scripts/functions and maybe upload some walkthroughs or explanations as needed (video clips?)
Example (2024)
- An example from 2024 - Day 1 to show how to go about a solution in Matlab.
Solutions
- Day 1
- Day 2 - not easy (
julia!) - Day 3 - a bit more straightforward
- Day 4 - toilet rolls!
- Day 5 - julia
BigIntsupport needed again… - Day 6 - cephalopod maths!
- Day 7 - part 1 ok - in part 2 I was defeated by my lack of
dynamic programmingfoo! - Day 8 - defeated something 😀
- Day 9 - Elves and red/green tiles. Part 1 straightforward, part 2 not solved.
- Day 10 - flicking switches… only read problem (time!)
- Day 11 - Pathfinding with
Graphs.jl(managed 1st part, 2nd part was tricky!)
Ideas
-
some things are easy to do in Matlab (arrays, tabular data, and so on). Some other things (eg reading in text data, files and converting into a reasonable shape) might end up a bit harder
-
a secondary consideration is to use Matlab’s language features to solve the puzzles efficiently (e.g. vectorization, matrix operations, and so on)
-
maybe some visualizations (plots, images, animations) where appropriate
-
ultmately, functions are better than scripts (more reusable, easier to test, and so on). So maybe try to write functions where possible.