private static char getNrMinesBBCase(char[][] m, int r, int c) {
        int n = 0;

        if (m[r - 1][c] == MINE) {
            n++;
        }
        if (m[r - 1][c + 1] == MINE) {
            n++;
        }
        if (m[r][c + 1] == MINE) {
            n++;
        }
        if (m[r + 1][c + 1] == MINE) {
            n++;
        }
        if (m[r + 1][c] == MINE) {
            n++;
        }
        if (m[r + 1][c - 1] == MINE) {
            n++;
        }
        if (m[r][c - 1] == MINE) {
            n++;
        }
        if (m[r - 1][c - 1] == MINE) {
            n++;
        }

        return (char) ('0' + n);
    }