Warning

This documents an unmaintained version of NetworkX. Please upgrade to a maintained version and see the current NetworkX documentation.

has_path

has_path(G, source, target)[source]

Return True if G has a path from source to target, False otherwise.

Parameters :

G : NetworkX graph

source : node

Starting node for path

target : node

Ending node for path