getZone static method
Implementation
static int getZone({int? index, int? row, int? col}) {
if (index == null) {
if (col == null || row == null) {
throw StateError("index or (col and row) can't be null");
}
} else {
row = getRow(index);
col = getCol(index);
}
int x = col ~/ 3;
int y = row ~/ 3;
return y * 3 + x;
}