Actually a great puzzle this pt2 was, I was trying to solve it by calculating number of square grids and recombining the cut-off and missing triangles, but it didn't work until I realized that you can't recombine them, they're opposite parity! And then I was able to solve this by subtracting the even cut-off triangles and filling in the missing odd triangles. This solution requires 4 fills only - even and odd for square and rhombus inside that square.
It works because summing up all the same parity triangles from all sides creates "S / N" missing and "S / N + 1" cut-off squares (!) with a cut-out rhombus in the middle ^^ And summing it up like this works because the empty wide diagonals and scarcity of the grid actually prove that all triangles inside and outside diagonals are filled up in steps required to reach the diagonal.
you mentioned that you'd like to hear if other people take more general approaches. people have solved this with a quadratic equation. since you do a great job of explaining solutions, it'd be great to hear your take on it. also thanks for the videos - its great they are explanation focused recodes, rather than watching someone silently figure it out first time.
Thanks for this idea! Yeah, people in my Discord server raised this idea and it certainly seems very interesting; I'll definitely go over it in my next review stream. Like you said though, it does still require some assumptions, but it's a lot more general than my solution, and actually seems to work on the test input too. Glad you've been enjoying!
I've just noticed that this number of steps 26501365 - is actually 202300 x 131+ 65 - which means that it is 65 steps to the edge of the current field and exactly 202300 full fields ahead. And I bet there must be some kind of geometric grow of the answer, so I think I'll try to manually extend the input like 5x5 and see what kind of answers I'll get after 65+131 and 65+ 2x131 , 65+ 3x131 steps. I bet there will be some kind of dependency and possibility to calculate N-th step answer
@@hyper-neutrino but why? isn't number of even grid only represent the grid that the entire plots travel? but from the diagram you clearly count the grid that suppose to be corner and edge that you also add to it later.
Curious...is your knowledge to come up with this solution due more to a strong math background or previous experience coding grid/game based movements?
A mix of both. This solution is more so from grid experience. There's actually a much nicer mathematical solution that I will visit during my next stream.
Interesting. I don't think that'd be possible, because ultimately you will end up with partial sections of the original grid, and I don't think we can fix that.
I thought you might get the internal diamond (reached with 65 steps) and then the diamond of all the corner triangles. Also, I thought that those empty diagonal lines on the grid when you zoom out might suggest that this is an idea...
This is a very elegant and very well explained solution, thanks a lot !
great work!
Actually a great puzzle this pt2 was, I was trying to solve it by calculating number of square grids and recombining the cut-off and missing triangles, but it didn't work until I realized that you can't recombine them, they're opposite parity! And then I was able to solve this by subtracting the even cut-off triangles and filling in the missing odd triangles. This solution requires 4 fills only - even and odd for square and rhombus inside that square.
It works because summing up all the same parity triangles from all sides creates "S / N" missing and "S / N + 1" cut-off squares (!) with a cut-out rhombus in the middle ^^ And summing it up like this works because the empty wide diagonals and scarcity of the grid actually prove that all triangles inside and outside diagonals are filled up in steps required to reach the diagonal.
you mentioned that you'd like to hear if other people take more general approaches. people have solved this with a quadratic equation. since you do a great job of explaining solutions, it'd be great to hear your take on it. also thanks for the videos - its great they are explanation focused recodes, rather than watching someone silently figure it out first time.
that said, it still seems to depend on the shape of the actual puzzle input, rather than generalise.
Thanks for this idea! Yeah, people in my Discord server raised this idea and it certainly seems very interesting; I'll definitely go over it in my next review stream. Like you said though, it does still require some assumptions, but it's a lot more general than my solution, and actually seems to work on the test input too. Glad you've been enjoying!
I've just noticed that this number of steps 26501365 - is actually 202300 x 131+ 65 - which means that it is 65 steps to the edge of the current field and exactly 202300 full fields ahead. And I bet there must be some kind of geometric grow of the answer, so I think I'll try to manually extend the input like 5x5 and see what kind of answers I'll get after 65+131 and 65+ 2x131 , 65+ 3x131 steps. I bet there will be some kind of dependency and possibility to calculate N-th step answer
And it worked, brute-forced till 327-th step, then used prediction algorithm from day10 and run it 202300 times.
at 14:24 I don't understand why you choose 4x4 instead of 2x2 for number of even grid. that 4x4 contain no full travel grid isn't it?
"If we add another layer around the outside..."
@@hyper-neutrino but why? isn't number of even grid only represent the grid that the entire plots travel? but from the diagram you clearly count the grid that suppose to be corner and edge that you also add to it later.
Just curious what application you are using when you write equations or draws diagrams? I like your solutions!
I use excalidraw
excalidraw
@@hyper-neutrino Thanks. It looks great on your videos
Curious...is your knowledge to come up with this solution due more to a strong math background or previous experience coding grid/game based movements?
A mix of both. This solution is more so from grid experience. There's actually a much nicer mathematical solution that I will visit during my next stream.
@@hyper-neutrino Thanks. If you remember, drop a note here. I'll watch for the video, but just in case.
If you are using VSCode, what theme and font you used? It seems awesome to me
Theme is GitHub Dark with Material Icons and the font is Monaspace Radon
I wondered if you could rotate the grid by 45 so that it would cut out all those edge bits....
Interesting. I don't think that'd be possible, because ultimately you will end up with partial sections of the original grid, and I don't think we can fix that.
I thought you might get the internal diamond (reached with 65 steps) and then the diamond of all the corner triangles. Also, I thought that those empty diagonal lines on the grid when you zoom out might suggest that this is an idea...
What's the code/package that allows you to run your code on both the input in white and the sample in blue?
It's a custom alias (you can find it in scripts.sh in my repository in the description)
Man, I've copied this exactly and it's still wrong...and I am smashing my head against the wall