code: def connect_predecessors(self, predecessors):
          
          for n in predecessors:
              self.ingoing.append(n)
              n.outgoing.append(self)
docs: Connect all nodes in predecessors to this node.