摘要: import re stringA = "abcdefghijk" pattern = re.compile(r'd(.+?)h') # 匹配d和h中间的内容 print(re.findall(pattern, stringA)) # ['efg'] stringB = "abcdefg(pytho 阅读全文
posted @ 2022-08-18 17:41 OTAKU_nicole 阅读(314) 评论(0) 推荐(0) 编辑