How can you find last match with python regular expressions
In this tutorial, you will learn about How to find last match with python regular expressions.
import re text="hi how are you ? " list = re.findall(r"\w+ \W+", text) print("last match:", list[len(list)-1])
last match: you ?
If you have any alternative methods or procedures for same requirement, you can comment below.