# recherche du plus court chemin print(nx.astar_path(H,(1.0, 4.0),(4.0, 2.0),dist)) [(1.0, 4.0), (1.0, 3.0), (1.0, 2.0), (2.0, 3.0), (3.0, 2.0), (4.0, 2.0)]
chemin le plus court ( H, graphe non orienté)
- 788 lectures
# recherche du plus court chemin print(nx.astar_path(H,(1.0, 4.0),(4.0, 2.0),dist)) [(1.0, 4.0), (1.0, 3.0), (1.0, 2.0), (2.0, 3.0), (3.0, 2.0), (4.0, 2.0)]