Please enable JavaScript to use regex101
/
^
r
e
g
e
x
[
\
-
_
]
?
1
0
1
$
/
i
Regular
Expressions
101
Regular
Expressions
101
Upgrade to Pro
Enterprise
Regular Expression
/
(b.*?)?apple
/
g
Input 1
1
New
>Matched dolphin elephant apple star dog cat apple banana >Unmatched map banana apple dog >Only the first apple matched, others are unmatched. map apple banana apple cat map apple banana apple banana apple >The first apple and the second apple matched, others are unmatched. map apple dog apple banana apple banana apple