def draw(g: nx.DiGraph): import matplotlib.pyplot as plt nx.draw_networkx(g, with_labels=True) plt.show()