docs: def add_hyperedges(self, hyperedges, attr_dict=None, **attr):
          """Adds multiple hyperedges to the graph, along with any related
              attributes of the hyperedges.
              If any node in the tail or head of any hyperedge has not
              previously been added to the hypergraph, it will automatically
              be added here. Hyperedges without a "weight" attribute specified
              will be assigned the default value of 1.
  
          :param hyperedges: iterable container to either tuples of
                      (tail reference, head reference) OR tuples of
                      (tail reference, head reference, attribute dictionary);
                      if an attribute dictionary is provided in the tuple,
                      its values will override both attr_dict's and attr's
                      values.
          :param attr_dict: dictionary of attributes shared by all
                      the hyperedges.
          :param attr: keyword arguments of attributes of the hyperedges;
                      attr's values will override attr_dict's values
                      if both are provided.
          :returns: list -- the IDs of the hyperedges added in the order
                      specified by the hyperedges container's iterator.
  
          See also:
          add_hyperedge
  
          Examples:
          ::
  
              >>> H = DirectedHypergraph()
              >>> xyz = hyperedge_list = ((["A", "B"], ["C", "D"]),
                                          (("A", "C"), ("B"), {'weight': 2}),
                                          (set(["D"]), set(["A", "C"])))
              >>> H.add_hyperedges(hyperedge_list)
  
          """
          attr_dict = self._combine_attribute_arguments(attr_dict, attr)
  
          hyperedge_ids = []
  
          for hyperedge in hyperedges:
              if len(hyperedge) == 3:
                  # See ("A", "C"), ("B"), {weight: 2}) in the
                  # documentation example
                  tail, head, hyperedge_attr_dict = hyperedge
                  # Create a new dictionary and load it with node_attr_dict and
                  # attr_dict, with the former (node_attr_dict) taking precedence
                  new_dict = attr_dict.copy()
                  new_dict.update(hyperedge_attr_dict)
                  hyperedge_id = self.add_hyperedge(tail, head, new_dict)
              else:
                  # See (["A", "B"], ["C", "D"]) in the documentation example
                  tail, head = hyperedge
                  hyperedge_id = \
                      self.add_hyperedge(tail, head, attr_dict.copy())
              hyperedge_ids.append(hyperedge_id)
  
          return hyperedge_ids