Please enable JavaScript to use regex101
/
^
r
e
g
e
x
[
\
-
_
]
?
1
0
1
$
/
i
Reg
ular
Ex
pressions
101
Upgrade to Pro
Enterprise
Regular Expression
r"
(?:^|\n)(([0-9]+)\.[\s\S]*?)(?=\n[0-9]+\.|\Z)
"
gm
Input 1
New
1. First sentence. 2. Second sentence. 1. Another sentence. 3. Third sentence.
Extraction
1. First sentence. 2. Second sentence. 1. Another sentence. 3. Third sentence.