Skip to content

Commit 86895b2

Browse files
A* Search Algorithm
1 parent 57ccc88 commit 86895b2

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

searches/astar.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,3 +135,4 @@ def neighbors(node: Node) -> Iterable[tuple[Node, float]]:
135135
goal: Node = (5, 5)
136136
path = astar(start, goal, neighbors, heuristic)
137137
print("Path found:", path)
138+
# Output: Path found: [(0, 0), (0, 1), (0, 2), (0, 3), (0, 4), (0, 5), (1, 5), (2, 5), (3, 5), (4, 5), (5, 5)]

0 commit comments

Comments
 (0)