@not_implemented_for('directed')
def node_connected_component(G, n):
 return set(_plain_bfs(G, n))

@ not_implemented_for ( 'directed' ) def node_connected_component ( G , n ) : return set ( _plain_bfs ( G , n ) )
return the nodes in the component of graph containing node n .