We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 28a122b commit ac84888Copy full SHA for ac84888
1 file changed
graphs/bidirectional_search.py
@@ -134,11 +134,15 @@ def bidirectional_search(
134
return None
135
136
# Construct path from start to intersection
137
- forward_path: list[int] = construct_path(current=intersection, parents=forward_parents)
+ forward_path: list[int] = construct_path(
138
+ current=intersection, parents=forward_parents
139
+ )
140
forward_path.reverse()
141
142
# Construct path from intersection to goal
- backward_path: list[int] = construct_path(current=backward_parents[intersection], parents=backward_parents)
143
+ backward_path: list[int] = construct_path(
144
+ current=backward_parents[intersection], parents=backward_parents
145
146
147
# Return the complete path
148
return forward_path + backward_path
0 commit comments