<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def altimeter(alt: Number, unit: str = 'hPa') -> str: """ Formats the altimter element into a string with hPa and inHg values Ex: 30.11 inHg (10.20 hPa) """

    if not (alt and unit in ('hPa', 'inHg')):
        return ''
    if unit == 'hPa':
        value = alt.repr
        converted = alt.value / 33.8638866667
        converted = str(round(converted, 2)) + ' inHg'  # type: ignore
    elif unit == 'inHg':
        value = alt.repr[:2] + '.' + alt.repr[2:]
        converted = float(value) * 33.8638866667
        converted = str(int(round(converted))) + ' hPa'  # type: ignore
    return f'{value} {unit} ({converted})'