Python 3 | Hash Table | Time O(n) | Space O(n) | Easy code
Complexity\n- Time complexity:\nO(n)\n\n- Space complexity:\nO(n)\n\n# Code\npython3 []\nclass Solution:\n    def circularGameLosers(self, n: int, k: int) -> Li
# Complexity\n- Time complexity:\nO(n)\n\n- Space complexity:\nO(n)\n\n# Code\n```python3 []\nclass Solution:\n    def circularGameLosers(self, n: int, k: int) -> List[int]:\n        dictSet = set()\n        count = 0\n\n        for i in range(1, n + 1):\n            dictSet.add(i)\n        # {1, 2, 3, 4, 5}\n\n        for j in range(n): \n\n            count = (count + (k * j)) % n\n\n            if count + 1 not in dictSet:    # 1) {1, 2, 3, 4, 5}\n                break                       # 2) {2, 3, 4, 5}\n            else:                           # 3) {2, 4, 5}\n                dictSet.remove(count + 1)   # 4) {4, 5}\n        # {4, 5}\n        return list(dictSet) # [4,5]\n```
['Array', 'Hash Table', 'Python3']