(1)从键盘输入一个字符串(串长不大于80). (2)以十进制输出字符串中非字母字符的个数(不是a to z或 A to Z). (3)输出原字符串且令非字母字符闪烁显示. (4)找出字符串中ASCII码值最大的字符,在字符串中用红色显示. (5)字符串的输入和结果的输出都要有必要的提示,且提示独占一行. (6)要使用到子程序. data segment hintinput db "please input a string:$" hintoutput1 db "The nu
python2.7默认的编码方式为ascii码,如下可以查询: import sys sys.getdefaultencoding() 如果直接在unicode和ascii字符串之间做计算.比较.连接,都会出错: s = '您好' u = u'您好' s == u __main__:1: UnicodeWarning: Unicode equal comparison failed to convert both arguments to Unicode - interpreting them