正则表达式分组功能实例 代码import re p = re.compile(r'(\d+)-(\d+)-(\d+)') print(p.match('2018-05-10').group(2)) print(p.match('2018-05-10').g... 3年前•Python笔记本 0