I want to write a simple regular expression in Python that extracts a number from HTML. The HTML sample is as follows:
Your number is 123
import re m = re.search("Your number is (\d+)", "xxx Your number is 123 fdjsk") if m: print m.groups()[0]