・ Shortest match ・ Longest match
[Example sentence] String = "Free Throw Challenge_hoge-san _1st time"
For the above string ① I want to extract only free throw challenges (extract before the first underscore) ② I want to extract the number of times (extract after the last underscore)
①-> re.search ("(. *?) (? = _)", String) [0] → Free throw challenge extracted ②-> re.search ("([^ _] * $)", x) [0] → The first time is extracted