Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何让 python 使用简体中文文本输入作为字符串或原始输入?
解码输入。
u = s.decode('gb2312')
windows vista 64位上python 2.6.2 32位中汉字的简单处理
>>> s = raw_input("Insert Chinese Text Here: ") 你好世界 >>> u'\u4f60\u597d\u4e16\u754c' >>> print s 你好世界 >>>