code: def add(self, item):
          
          with self.lock:
              if item in self.set:
                  return False
              self.set.add(item)
              return True
docs: Add an item to the set, and return whether it was newly added