def language(filename):
    """Gets the language which the source code file filename was written in
    based on its extension.

    """
    name, ext = os.path.splitext(filename)
    if ext not in EXTENSIONS:
        raise LanguageError ("Error 1: file is not source code or language is"
                             "not supported.")
    return EXTENSIONS[ext]
dataset/ETHPy150Open the-xkcd-community/the-red-spider-project/src/level_up.py/language/original