Graph.neighbors

Graph.neighbors(key)[source]

Return the neighbors of a node.

Parameters

key (hashable) – The identifier of the node.

Returns

list[hashable] – A list of node identifiers.