如果匹配不成功,则返回None。匹配成功对象可调用group()方法来显示那个成功的匹配。如:. m = re.match('foo', 'foobar') if m is not None: m.group() ...
確定! 回上一頁