[Tutor] google search

2012-07-14 Thread Goog Cheng
Hi, all! I wanna get the number of results for a query term from google , I tried some methods , xgoogle is the commonest way but still doesn't work well (BWT i'm a beginner) , Could you give me some advice or i have to simulate the browser(still unskilled) , I'm pressed for time and to calcul

[Tutor] the regex boundary about chinese word

2012-05-03 Thread goog cheng
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