Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2022 - Day 23 #215

Open
wants to merge 13 commits into
base: master
Choose a base branch
from
Open

2022 - Day 23 #215

wants to merge 13 commits into from

Conversation

romellem
Copy link
Owner

The required game-of-life-esque puzzle!

Nothing super complicated, but one huge easy thing to miss in your implementation:

  • When looping your proposals for the elf, if it finds one, stop looping! My big bug was I always looped through the 4 options, and picked the last correct one.

Otherwise, InfiniteGrid is fairly handy here, except when it comes to part 2. There, its inability to loop through specific cells is obvious, as part 2 takes a long time. I need to loop over my entire grid every time, when really all I should be doing is looping over ELF cells. Oh well, still takes less than 10 seconds so fast enough for me!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant