rustworkx.PyDiGraph.num_nodes

PyDiGraph.num_nodes()

Return the number of nodes in the graph