xpxu
f1=file("hello.txt")
count=0
s=f1.read()
li=re.findall("hello",s)
if len(li)>0:
    count=count+li.count("hello")
print str(count)
f1.close()

 

分类:

技术点:

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-11-23
  • 2021-05-19
  • 2021-08-04
  • 2022-12-23
  • 2022-12-23
  • 2021-11-29
猜你喜欢
  • 2022-12-23
  • 2021-07-12
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案