code: def unique(self, key=None):
          
          if key is None:
              seen = set()
              seen_add = seen.add
  
              return self.__class__([x for x in self.items if not (x in seen or seen_add(x))])
  
          key = self._value_retriever(key)
  
          exists = []
  
          def _check(item):
              id_ = key(item)
              if id_ in exists:
                  return True
  
              exists.append(id_)
  
          return self.reject(_check)
docs: Return only unique items from the collection list.
  
          :param key: The key to chech uniqueness on
          :type key: mixed
  
          :rtype: Collection