rustworkx.PyDAG.neighbors#
- PyDAG.neighbors(node, /)#
Get the neighbors (i.e. successors) of a node.
This will return a list of neighbor node indices. This function is equivalent to
successor_indices()
.- Parameters:
node (int) – The index of the node to get the neighbors of
- Returns:
A list of the neighbor node indices
- Return type: