demo_regex_meta2.py:
import re str = "That will be 59 dollars" #Find all digit characters: x = re.findall("\d", str) print(x)
➜ begtut>python demo_regex_meta2.py
['5', '9']