sudokusolver.py
def validate_number(self, row: int, column: int, number: int) -> bool:
        '''
        Checks if number is available in place indicated by coordinates.
        If such number is already present in row, column or box, method returns False.
        :param row: row coordinate of cell
        :param column: column coordinate of cell
        :param number: number for checking
        :return: True if number is valid in this place, False otherwise
        '''
        if number in self.sudoku[row, :]:
            return False
        if number in self.sudoku[:, column]:
            return False
        box_row, box_column = row // 3 * 3, column // 3 * 3
        if number in self.sudoku[box_row:box_row + 3, box_column:box_column + 3]:
            return False
        return True

        Checks if number is available in place indicated by coordinates.
        If such number is already present in row, column or box, method returns False.
        :param row: row coordinate of cell
        :param column: column coordinate of cell
        :param number: number for checking
        :return: True if number is valid in this place, False otherwise
        
Checks if number is available in place indicated by coordinates.
If such number is already present in row, column or box, method returns False.
Checks if number is available in place indicated by coordinates . If such number is already present in row column or box method returns False .
def validate_number(self, row: int, column: int, number: int) -> bool:
        if number in self.sudoku[row, :]:
            return False
        if number in self.sudoku[:, column]:
            return False
        box_row, box_column = row // 3 * 3, column // 3 * 3
        if number in self.sudoku[box_row:box_row + 3, box_column:box_column + 3]:
            return False
        return True
def validate_number ( self , row : int , column : int , number : int ) -> bool : if number in self . sudoku [ row , : ] : return False if number in self . sudoku [ : , column ] : return False box_row , box_column = row // 3 * 3 , column // 3 * 3 if number in self . sudoku [ box_row : box_row + 3 , box_column : box_column + 3 ] : return False return True
Checks if number is available in place indicated by coordinates.
Checks if number is available in place indicated by coordinates .
'''
        Checks if number is available in place indicated by coordinates.
        If such number is already present in row, column or box, method returns False.
        :param row: row coordinate of cell
        :param column: column coordinate of cell
        :param number: number for checking
        :return: True if number is valid in this place, False otherwise
        '''
True if number is valid in this place, False otherwise
True if number is valid in this place False otherwise
self
row
int
row coordinate of cell
row coordinate of cell
column
int
column coordinate of cell
column coordinate of cell
number
int
number for checking
number for checking