Artificial Intelligence, Data Science, Machine Learning, Programming, Technology.
these cities import networkx as nx import matplotlib.pyplot as plt WG = nx.Graph() city_graph = city_graph = [('Chennai', 'Delhi',{'distance':700}), ('Mumbai', 'Chennai',{'distance':300}), ('Delhi', 'Kolkata',{'distance':1000}), ('Delhi', 'Bangalore',{'distance':20}), ('Chennai',