Mega Code Archive
Categories
/
Perl
/
Regular Expression
B matches only if the pattern is contained in a word
/\Bdef/ matches abcdef, but not def. /def\B/ matches defghi, /\Bdef\B/ matches cdefg or abcdefghi