sys.stdout = io.TextIOWrapper(sys.stdout.buffer, encoding='gb18030')原文 http://blog.csdn.net/jim7424994/article/details/22675759