text = 'this is a text'
found = re.search('is(.+?)text', text).group(1)
# AAA, ZZZ not found in the original string
found = '0 wtitle' # apply your error handling
Tip: You can change the style, width & colours of the snippet with the
inspect tool before clicking Download!