AdventOfCode2021 - Day 9

This is a thread to discuss Day9
https://adventofcode.com/2021/day/9

REMEMBER!
It is VERY important NOT to write any public spoilers :slight_smile:
ALWAYS keep spoiler stuff hidden inside one of these

Summary

This text will be hidden

which you can obtain by clicking on the gear icon

image

Part 1 Duration 300 ms
Part 2 Duration 900 ms
Project using Snap!7 rc2

You have a speedy computer, when i run your code: part 1 = 500ms, part 2 = 2300ms

It was brand new last week :slight_smile:

project

only part 1 for me :
....1st attempt: 6.6 sec
....2nd attempt: 2.1 sec
....3rd attempt: 1.2 sec

@cymplecy

My 1st idea was like you: a border of 9.
But i try to without this border: bad idea. The code as much "if then else" than i have teeths in my mouth (I have a lot of teeths).

Summary

I think adding the border is the key to simplifying this one :slight_smile: