beats 85%;
Intuition\n Describe your first thoughts on how to solve this problem. \n\n# Approach\n Describe your approach to solving the problem. \n\n# Complexity\n- Time 
# Intuition\n<!-- Describe your first thoughts on how to solve this problem. -->\n\n# Approach\n<!-- Describe your approach to solving the problem. -->\n\n# Complexity\n- Time complexity:\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\n\n- Space complexity:\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# Code\n```\nclass Solution:\n\n    def __init__(self, m, n):\n        self.m = m\n        self.n = n\n        self.flipped = Counter()\n        \n\n    def flip(self):\n        i, j = random.randint(0, self.m-1), random.randint(0, self.n-1)\n        while self.flipped[(i, j)] == 1:\n            i, j = random.randint(0, self.m-1), random.randint(0, self.n-1)\n        self.flipped[(i, j)] = 1\n        return (i, j)\n\n    def reset(self):\n        self.flipped = Counter()\n```
['Python']