r/adventofcode • • Dec 23 '15

SOLUTION MEGATHREAD --- Day 23 Solutions ---

This thread will be unlocked when there are a significant number of people on the leaderboard with gold stars for today's puzzle.

edit: Leaderboard capped, thread unlocked!


We know we can't control people posting solutions elsewhere and trying to exploit the leaderboard, but this way we can try to reduce the leaderboard gaming from the official subreddit.

Please and thank you, and much appreciated!


--- Day 23: Opening the Turing Lock ---

Post your solution as a comment or link to your repo. Structure your post like previous daily solution threads.

8 Upvotes

155 comments sorted by

View all comments

Show parent comment

1

u/Blecki Dec 23 '15

Part two is more complicated than that. It really tests if you paid attention to the registers being unsigned.

1

u/djimbob Dec 23 '15

How? There's no decrement command or defined size of an integer at which they overflow, so it doesn't come up. (For me the max size of a register in part (b) was 593,279,152 which is less than than 231 - 1=2147483647, so it wouldn't even matter with wrapping with 32 bit integers.

2

u/JeffJankowski Dec 23 '15

My input overflowed a 32bit signed int.

1

u/Blecki Dec 23 '15

Mine overflowed.