system.py 文件源码

python
阅读 28 收藏 0 点赞 0 评论 0

项目:Python-Plex-Controller 作者: MoeFwacky 项目源码 文件源码
def spellchecker(title):
    try:
        d = enchant.Dict("en_US")
    except ImportError:
        print ("Enchant Library Not Found. Spell Checking Failed.")
        return title
    options = []
    newt = ""
    ccount = 0
    fail = "no"
    for word in title.split(" "):
        if d.check(word) is True:
            newt = newt + word + " "
        else:
            clist = d.suggest(word)
            word = clist[ccount]
            newt = newt + word + " "
            fail = "yes"
    return newt
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号