def get_location(patent_html):
    """Gets location of company associated with patent entry (dict)."""
    # Grab metadata table
    ass_loc = patent_html.find(text="Assignee:").find_next()
    # Split tag contents so that only first assignee location is retrieved
    ass_text = ass_loc.text.split('\n\n')[0].replace('\n', '')
    lind = ass_text.find("(")
    rind = ass_text.rfind(")")
    return ass_text[lind + 1:rind]