goog cheng wrote:
> Hi, I got this problem :
>
> #!python
> # -*- coding: utf-8 -*-
> import re
>
> p = re.compile(ur'\bc123\b')
> print '**',p.search('no class c123 at all').group()
>
> p = re.compile(ur'\b\u7a0b\u6770\b')
> print ur'\u7a0b\u6770'
> print '',p.search(' 程杰 abc'.decode('utf
Hi, I got this problem :
#!python
# -*- coding: utf-8 -*-
import re
p = re.compile(ur'\bc123\b')
print '**',p.search('no class c123 at all').group()
p = re.compile(ur'\b\u7a0b\u6770\b')
print ur'\u7a0b\u6770'
print '',p.search(' 程杰 abc'.decode('utf8'))
why the \b boundary can't match t