code: def BFS_Tree(G, start):
      
      if start not in G.vertices:
          raise GraphInsertError("Vertex %s doesn't exist." % (start,))
      pred = BFS(G, start)
      T = digraph.DiGraph()
      queue = Queue()
      queue.put(start)
      while queue.qsize() > 0:
          current = queue.get()
          for element in pred:
              if pred[element] == current:
                  T.add_edge(current, element)
                  queue.put(element)
      return T
docs: Return an oriented tree constructed from bfs starting at 'start'.