'Return True if n is a node, False otherwise. Use the expression
\'n in G\'.
Examples
>>> G = nx.path_graph(4)  # or DiGraph, MultiGraph, MultiDiGraph, etc
>>> 1 in G
True'

def __contains__(self, n):

    try:
        return (n in self._node)
    except TypeError:
        return False
