how to match u'\uff00' - u'\uff0f' in re module?

yichao.zhang yichao.zhang at gmail.com
Mon Jul 10 22:32:24 EDT 2006


I'm trying to match the characters from u'\uff00' to u'\uff0f'.
the code below and get a TypeError.
p = re.compile(u'\uff00'-u'\uff0f')
Traceback (most recent call last):
  File "<interactive input>", line 1, in ?
TypeError: unsupported operand type(s) for -: 'unicode' and 'unicode'


so re module does NOT support this operation
however, is there any alternative way to solve my problem?

Any comments/suggestions much appreciated!




More information about the Python-list mailing list