Python判断子字符串在母字符串的数目

len(re.findall(value,password))

 

 

或者用“”.count()

 

print(a.count(b)) #2

posted @ 2020-12-26 17:06  bH1pJ  阅读(33)  评论(0编辑  收藏  举报