How to access an element from a list of lists in python networkX? TypeError: 'int' object is not iterable

前端 未结 0 1145
余生分开走
余生分开走 2021-01-13 06:31

I have an output from my loop, where G is a Graph from networkX.

for node in G.nodes():
    start_end = [(node,k) for k,v in nx.shortest_path_length(G, node)         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题