AdjacencyList
AdjacencyList[g,v] gives a list of vertices adjacent to vertex v.
AdjacencyList[g,patt] gives a list of vertices adjacent to vertices that match the pattern patt.
AdjacencyList[g,patt,d] gives a list of vertices that are at distance at most d.
AdjacencyList[{v->w,…},…] uses rules v->w to specify the graph g.
Please visit the official Wolfram Language Reference for more details and examples on core symbols.