How to check the current array position with other cases

i’m a beginning coder so this probably won’t be the last time i post on here but anyway, onto my problem. I am trying to figure out how to check the current array position and set the values to the four ints below the method, any help would be appreciated
Thank you!

public static void main(String[] args) {
    boolean[][] nbrs = { { true, false, false, true }, { false, false, true, true }, { true, true, false, true },
            { false, true, false, false } };

    System.out.println(howManyNeighbors(nbrs, 0, 2)); // 3
    System.out.println(howManyNeighbors(nbrs, 1, 1)); // 4
    System.out.println(howManyNeighbors(nbrs, 3, 3)); // 1
}

public static int howManyNeighbors(boolean[][] n, int row, int col) {
    int startR, startC, endR, endC;
    int numNbrs = 0;

    /***
     * TODO: Set the values of startR, startC, endR, and endC to include the row
     * above and below the given input row, and the column above and below the given
     * input col, checking and adjusting for invalid array indices
     ***/
    startR = numNbrs;
    startC = numNbrs;
    endR = numNbrs;
    endC = numNbrs;

    for (int r = startR; r <= endR; r++) {
        for (int c = startC; c <= endC; c++) {
            /***
             * TODO: Check the current array position, and if it is (1) true, and (2) not
             * the input row and col, execute the following block
             ***/

            if (numNbrs == -1 && numNbrs != row && numNbrs != col) {
            }

            numNbrs++;
        }
    }
    return numNbrs;
}

}