+ 2
Pattern Regular Expressions
Suppose I have two words Frun and Run I want to write a regex pattern that only matches run not frun. Someone help me to write a pattern for that.... I would be kind enough.
5 Respostas
+ 9
Use this - /run/g
or /run/gi for case insensitive
for eg-
var str = "run frun";
var patt= /run/g;
var res= str.match(patt);
+ 1
Thank you calvin so nice of you
0
Use this site to try different patterns:
https://regexr.com/3qd4k
0
try this:"\b(?!F)Run\b"