def unwrap_links(soup):
    """
    unwrap <a> elements (remove links) if link target contains
    removed directories: players/ leagues/ coaches/ teams/

    returns a tuple:
    (soup, n_unwrapped_links)
    """
    unwrapped_links = 0
    hrefs = soup.body.find_all('a')
    for elem in hrefs:
        if (
            'players/' in elem['href']
            or
            'coaches/' in elem['href']
            or 
            'leagues/' in elem['href']
            or
            'teams/' in elem['href']
        ):
            elem.unwrap()
            unwrapped_links += 1
    return (soup, unwrapped_links)