Java Fastest solution with no Data Structure
\nclass Solution {\n    int i = 0, j = 0, m, n;\n    \n    public Solution(int m, int n) {\n        this.m = m;\n        this.n = n;\n    }\n    \n    public in
```\nclass Solution {\n    int i = 0, j = 0, m, n;\n    \n    public Solution(int m, int n) {\n        this.m = m;\n        this.n = n;\n    }\n    \n    public int[] flip() {\n        j ++;\n        if(j == n){\n            j = 0; i ++;\n        }\n        if(i == m){\n            i = 0; j = 0;\n        }\n        return new int[]{i, j};\n    }\n    \n    public void reset() {\n        \n    }\n}\n```
['Java']