Stream: advent of code

Topic: 2024 Day17


view this post on Zulip Oskar Hahn (Dec 18 2024 at 00:02):

This was a fun one: https://github.com/ostcar/aoc2024/blob/main/day17.roc

part1 in 23.117us
part2 in 237.182us

view this post on Zulip Paul Stanley (Dec 18 2024 at 09:54):

It was a fun one! I massively over-engineered the computer, and made a silly mistake in not building the program into the machine but couldn't be bothered to re-engineer.

https://gist.github.com/PaulStanley/6c2efa227c29ccd1b86084508a70a315

Part One: ... [0 ms].
Part Two: ... [2 ms].

view this post on Zulip Ben Thomas (enkidatron) (Dec 19 2024 at 04:03):

The optimizer seems to not like my style of recursion or something. roc build --optimize day17.roc && ./day17 says it cannot find an answer while roc dev day17.roc gives the correct answer. Are there known cases of the optimizer changing a programs output?

view this post on Zulip Brendan Hansknecht (Dec 19 2024 at 04:04):

There is #bugs > opportunistic mutation bug with "--optimize"?

view this post on Zulip Ben Thomas (enkidatron) (Dec 19 2024 at 04:12):

Thank you! I will check the #bugs channel next time


Last updated: Jul 06 2025 at 12:14 UTC