File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed
main/java/com/adventofcode/flashk/day16
test/java/com/adventofcode/flashk/day16 Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -70,7 +70,9 @@ private long dijkstra(Tile start) {
7070
7171 // Initialize start tile
7272 start .setScore (0 );
73- start .setDirection (Vector2 .right ());
73+ if (start .getDirection () == null ) {
74+ start .setDirection (Vector2 .right ());
75+ }
7476
7577 // Execute dijkstra
7678 PriorityQueue <Tile > tiles = new PriorityQueue <>();
@@ -171,14 +173,14 @@ public long solveB(){
171173 if (adjacentScore == score ) {
172174 fillPath (adjacent , endTile );
173175 fillPath (adjacent , startTile );
174- paint ();
176+
175177 System .out .println ();
176178 }
177179 }
178180 }
179181 // Pasada 2, buscamos caminos alternativos en cada una de las intersecciones.
180182
181- // paint();
183+ paint ();
182184 return countPathTiles ();
183185 }
184186
Original file line number Diff line number Diff line change @@ -190,7 +190,7 @@ public void testSolvePart2Input() {
190190 System .out .println ("Solution: " +reindeerMaze .solveB ());
191191
192192 // 512 -> too low
193-
193+
194194 assertEquals (0L ,0L );
195195
196196 }
You can’t perform that action at this time.
0 commit comments