觉得代码在这个网站里看起来好清晰欧,似乎在这里整理代码笔记比在evernote里面好
例如re.compile 的功用:
The sequence
prog=re.compile(pattern)result=prog.match(string)
is equivalent to
result=re.match(pattern,string)
but using re.compile() and saving the resulting regular expression object for reuse is more efficient when the expression will be used several times in a single program.