def readFile(path):
    _info('Start building graph...')
    graph = Graph()
    with codecs.open(path, 'r', 'utf-8') as file:
        data = file.read().split('\n')
    for line in data:
        line_split = line.split(' ')
        (u, other) = (line_split[0], line_split[1:])
        u_obj = Vertex(u)
        for v in other:
            v_obj = Vertex(v)
            graph.addEdge(u_obj, v_obj)
    _info('Finish building graph...')
    return graph
def readFile(path):
    _info('Start building graph...')
    graph = Graph()
    with codecs.open(path, 'r', 'utf-8') as file:
        data = file.read().split('\n')
    for line in data:
        line_split = line.split(' ')
        (u, other) = (line_split[0], line_split[1:])
        u_obj = Vertex(u)
        for v in other:
            v_obj = Vertex(v)
            graph.addEdge(u_obj, v_obj)
    _info('Finish building graph...')
    return graph