def get_more_constrained_square(board):
    """Get the square in board with more constrains (less alternatives)."""
    ranges = ((x, y) for x in range(9) for y in range(9))
    constrains = [(len(get_alternatives_for_square(board, r, c)), (r, c)) 
        for (r, c) in ranges if not board[r][c]]
    if constrains:
        return min(constrains)[1]
Get the square in board with more constrains (less alternatives).
recipes/Python/577188_Sudoku_solver_functionalprogramming/recipe-577188.py