Perl defines the following zero-width assertions:
\b Match a word boundary
\B Match except at a word boundary
\A Match only at beginning of string
\Z Match only at end of string, or before newline at
the end
\z Match only at end of string
\G Match only at pos() (e.g. at the end-of-match position of prior m//g)
A word boundary (\b ) is a spot between two characters that has a \w on one side of it and a \W on the other side of it (in either order), counting the imaginary characters
off the beginning and end of the string as matching a \W . (Within character classes \b represents backspace rather than a word boundary, just as it normally does in any double-quoted string.)
For details please see http://perldoc.perl.org/perlre.html#Regular-Expressions
Thank you, but I already read this info on that (and many other) sites and I don't understand it. It is as far as I understand, written for people that already know something perl. I don't, and that information doesn't make it any clearer. That's why I thought someone here could explain it in simple words, but I was wrong. Sorry for have taken your time.