code: def dfs_tree(graph, start=0):
      
      to_visit = [start]
      prec = [None] * len(graph)
      while to_visit:              # an empty queue equals False
          node = to_visit.pop()
          for neighbor in graph[node]:
              if prec[neighbor] is None:
                  prec[neighbor] = node
                  to_visit.append(neighbor)
      return prec
docs: DFS, build DFS tree in unweighted graph
  
         :param graph: directed graph in listlist or listdict format
         :param int start: source vertex
         :returns: precedence table
         :complexity: `O(|V|+|E|)`