go 1.21, clean code
golang []\ntype Solution struct {\n\tm       int\n\tn       int\n\ttotal   int\n\tflipMap map[int]int\n}\n\nfunc Constructor(m int, n int) Solution {\n\treturn 
```golang []\ntype Solution struct {\n\tm       int\n\tn       int\n\ttotal   int\n\tflipMap map[int]int\n}\n\nfunc Constructor(m int, n int) Solution {\n\treturn Solution{\n\t\tm:       m,\n\t\tn:       n,\n\t\ttotal:   m * n,\n\t\tflipMap: make(map[int]int),\n\t}\n}\n\nfunc (this *Solution) Flip() []int {\n\trandIndex := rand.Intn(this.total)\n\tthis.total--\n\tx := randIndex\n\tif val, ok := this.flipMap[randIndex]; ok {\n\t\tx = val\n\t}\n\tif val, ok := this.flipMap[this.total]; ok {\n\t\tthis.flipMap[randIndex] = val\n\t} else {\n\t\tthis.flipMap[randIndex] = this.total\n\t}\n\treturn []int{x / this.n, x % this.n}\n}\n\nfunc (this *Solution) Reset() {\n\tthis.total, this.flipMap = this.m*this.n, make(map[int]int)\n}\n```
['Go']