def _get_max_size(x, y, map_info):
    """
    Get the size of the biggest square matrix in the map
    with first point: (x, y)
    
    Arguments:
    x -- column index
    y -- line index
    map_info -- a dict of the map and its information
    
    Returns:
    size -- biggest square matrix size
    """
    x_max = map_info["line_len"]
    y_max = map_info["line_num"]
    return min(x_max-x, y_max-y)