def discard(self, elem):
        """Remove an element from the set. Do nothing if elem is not in the set."""
        try:
            self.elems.remove(elem)
        except ValueError:
            pass
Remove an element from the set. Do nothing if elem is not in the set.
recipes/Python/106469_Yet_another_Set_class_for_Python/recipe-106469.py