If used take next available, 95% speed
Runtime: 48 ms, faster than 95.00% of Python3 online submissions for Random Flip Matrix.\nMemory Usage: 14.7 MB, less than 59.17% of Python3 online submissions 
Runtime: 48 ms, faster than 95.00% of Python3 online submissions for Random Flip Matrix.\nMemory Usage: 14.7 MB, less than 59.17% of Python3 online submissions for Random Flip Matrix.\n```\nfrom random import randint\nclass Solution:\n\n    def __init__(self, n_rows: int, n_cols: int):\n        self.rows = n_rows\n        self.cols = n_cols\n        self.len_range = n_rows * n_cols\n        self.upper_limit = self.len_range - 1\n        self.used = set()\n\n    def flip(self):\n        val = randint(0, self.upper_limit)\n        while val in self.used:\n            val += 1\n            if val == self.len_range:\n                val = 0\n        self.used.add(val)\n        return list(divmod(val, self.cols))\n\n    def reset(self) -> None:\n        self.used = set()\n```
['Python', 'Python3']