Python匹配字符串中的数字:

import re
s='zs10nj23kl'
f1=re.findall('(\d+)',s)
print(f1)

输出为:

['10', '23']

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-11-18
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-09-03
  • 2021-12-12
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-12-12
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案