Help for this page
m#this#; s!foo!bar!; s{this}<that>; m!word/word/word/word!
my $sting = 'all the metachars |+*?(){}-[]^$. '; $regex_safe = quotemeta $string; ... # to do what you want perhaps you might use... m!(?:[\w ]+/){3}[\w ]+!;