def extension(path : str) -> str:
    """Return the extension of the given path"""
    idx = path.rfind('.')
    if idx == -1:
        return '' 

    if idx == 0:
        return ''

    return path[idx+1:]