Skip to content

Commit

Permalink
Typo fix
Browse files Browse the repository at this point in the history
  • Loading branch information
derailed-dash committed Jan 22, 2024
1 parent c08d6a9 commit e7bfa1f
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/AoC_2023/Dazbo's_Advent_of_Code_2023.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -6599,7 +6599,6 @@
"\n",
"# SETUP LOGGING\n",
"logger.setLevel(logging.DEBUG)\n",
"# td.setup_file_logging(logger, locations.output_dir)\n",
"\n",
"# Retrieve input and store in local file\n",
"try:\n",
Expand Down Expand Up @@ -6648,7 +6647,7 @@
"\n",
"I found this one pretty tough.\n",
"\n",
"It was pretty obvious from the start that I needed either [Dijkstra’s or A* algorithm][https://aoc.just2good.co.uk/python/shortest_paths] to find the path with the lowest cumulative cost. But the actual implementation took me ages to get right.\n",
"It was pretty obvious from the start that I needed either [Dijkstra’s or A* algorithm](https://aoc.just2good.co.uk/python/shortest_paths) to find the path with the lowest cumulative cost. But the actual implementation took me ages to get right.\n",
"\n",
"So... We need to find a path from a start to a goal, where the cost varies depending on the path taken. As usual for a Dijkstra, we need to use a [priority queue](https://aoc.just2good.co.uk/python/priority_queues). First, we need to define some way to represent the state of our journey through the map. I'll represent state in a tuple that stores `(cost, current position, direction, straight steps taken)`. It's important that `cost` comes first, because our priority queue pops the next state based on the lowest value of the first item in the tuple.\n",
"\n",
Expand Down

0 comments on commit e7bfa1f

Please sign in to comment.