private boolean isValidBlock(int[][] game, int x, int y, int testNumber) {
        //declare variables referencing 3x3 block location in 9x9 grid
        int blockX, blockY;
        
        //determine row of 3x3 block being tested
        if (x < 3) 
            blockX = 0; //rows 0, 1, 2
        else if (x < 6)
            blockX = 3; //rows 3, 4, 5
        else
            blockX = 6; //rows 6, 7, 8
        
        //determine column of 3x3 block being tested
        if (y < 3)
            blockY = 0; //columns 0, 1, 2
        else if (y < 6)
            blockY = 3; //columns 3, 4, 5
        else
            blockY = 6; //columns 6, 7, 8
        
        while (y < blockY + 3) {
            while (x < blockX + 3) {
                if (game[blockY][blockX] == testNumber) 
                    return false; //testNumber exists in 3x3 block
                x++;
            }
            y++;
        }
        return true; //testNumber does not exist in 3x3 block
        
    }