code: def add_to_dict_val_set(dict_obj, key, val):
      
      try:
          dict_obj[key].add(val)
      except KeyError:
          dict_obj[key] = set([val])
docs: Adds the given val to the set mapped by the given key.
      If the key is missing from the dict, the given mapping is added.
  
      Example
      -------
      >>> dict_obj = {'a': set([1, 2])}
      >>> add_to_dict_val_set(dict_obj, 'a', 2)
      >>> print(dict_obj['a'])
      {1, 2}
      >>> add_to_dict_val_set(dict_obj, 'a', 3)
      >>> print(dict_obj['a'])
      {1, 2, 3}