任何想法,如果可以使用正则表达式(python 2.7)将uniq字符不加注为unicode字素的替代对?
根据This Example,这在python 3.x中是可能的。 看到这里:
>>> import regex
>>> s = ''
>>> for c in regex.findall('\X',s):
... print(c)
...
但是对于python 2.7似乎不起作用。参见示例:
>>> import regex
>>> s = ''
>>> for c in regex.findall('\X',s):
... print(c)
�
�
�
�
�
�
�
�
...
任何想法如何使它适用于python 2.7?=)))))
提前向您致敬!!! =)