阅读背景:

在python中将一些字符串(utf-8或其他)转换为简单的ASCII字符串的简单方法是什么?

来源:互联网 

Inside my python scrip, I get some string back from a function which I didn't write. The encoding of it varies. I need to convert it to ascii format. Is there some fool-proof way of doing this? I don't mind replacing the non-ascii chars with blanks or something else...Inside my python scrip, I get some string back




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: