def find_next_empty(puzzle):
    """
    Finds the next empty row or column that is not yet filled
    :param puzzle:
    :return:tuple(row,col) or (None,None) if no more space
    """
    for r in range(9):
        for c in range(9):
            if puzzle[r][c] == -1:
                return r, c  # if rth row and cth col is empty then return that row and column
    return None, None