<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def exceptions_by_country(country_code):
 """ Returns a list of exception names for the given country :param country_code: The two-character country code for the user :raises: ValueError - if country_code is not two characers :return: A list of strings that are VAT exceptions for the country specified """


    if not country_code or not isinstance(country_code, str_cls) or len(country_code) != 2:
        raise ValueError('Invalidly formatted country code')

    country_code = country_code.upper()

    return EXCEPTIONS_BY_COUNTRY.get(country_code, [])