code: def largest_compartment_id_met(model):
      
      # Sort compartments by decreasing size and extract the largest two.
      candidate, second = sorted(
          ((c, len(metabolites_per_compartment(model, c)))
           for c in model.compartments), reverse=True, key=itemgetter(1))[:2]
      # Compare the size of the compartments.
      if candidate[1] == second[1]:
          raise RuntimeError("There is a tie for the largest compartment. "
                             "Compartment {} and {} have equal amounts of "
                             "metabolites.".format(candidate[0], second[0]))
      else:
          return candidate[0]
docs: Return the ID of the compartment with the most metabolites.
  
      Parameters
      ----------
      model : cobra.Model
          The metabolic model under investigation.
  
      Returns
      -------
      string
          Compartment ID of the compartment with the most metabolites.