Shortest Path with Bidirectional Search

From NovaOrdis Knowledge Base
Revision as of 20:36, 9 November 2021 by Ovidiu (talk | contribs) (→‎Internal)
Jump to navigation Jump to search

Internal

Overview

Bidirectional search can be used to find the shortest path between a source and a destination node. It operates by running two simultaneous breadth-first searches, one from each node. When their searches collide, we have found the shortest path. This algorithm is faster than the classic breadth-first search based shortest path.