def has_ext(filename, ext):
    """
    >>> has_ext('test.mp3',['opus','mp3','aac'])
    True
    >>> has_ext('test.mp4',['opus','mp3','aac'])
    False
    >>> has_ext('test.opus.gz',['opus','mp3','aac'])
    False
    >>> has_ext('test.1.OPUS',['opus','mp3','aac'])
    True
    """

    return filename.split(".")[-1].lower() in ext