Python simple solution (no cheating) with complete explanation (video + code)
https://www.youtube.com/watch?v=w9JhOKb4tyk\n\nclass MyHashSet:\n\n    def __init__(self):\n        """\n        Initialize your data structure here.\n        "
https://www.youtube.com/watch?v=w9JhOKb4tyk\n```\nclass MyHashSet:\n\n    def __init__(self):\n        """\n        Initialize your data structure here.\n        """\n        self.size = 10000\n        self.table = [None] * self.size\n    \n    def calculate_hash_value(self, key):\n        return key % self.size\n\n    def add(self, key: int) -> None:\n        hv = self.calculate_hash_value(key)\n        \n        if self.table[hv] == None:\n            self.table[hv] = [key]\n        else:\n            self.table[hv].append(key)\n\n    def remove(self, key: int) -> None:\n        hv = self.calculate_hash_value(key)\n        \n        if self.table[hv] != None:\n            while key in self.table[hv]: \n                self.table[hv].remove(key)\n\n    def contains(self, key: int) -> bool:\n        """\n        Returns true if this set contains the specified element\n        """\n        hv = self.calculate_hash_value(key)\n        \n        if self.table[hv] != None:\n            return key in self.table[hv]\n        return False\n                \n\n\n# Your MyHashSet object will be instantiated and called as such:\n# obj = MyHashSet()\n# obj.add(key)\n# obj.remove(key)\n# param_3 = obj.contains(key)\n```
['Python3']