Foreword
a) Take a long tour here?:
http://www.regular-expressions.info/tutorial.html[
^]
b) Install this little tool, and play with it:
http://www.weitz.de/regex-coach/[
^]
Now the explanation
\w stands for "word character", usually [A-Za-z0-9_]. Notice the inclusion of the underscore and digits.
[^\s] stands for everything but whitespaces
Whilst
()+ means that all this together can be repeated at least once
As you have two character classes consecutively, your matched string needs to have at least two characters. Every odd character has to match the first class, every even character has to match the second one.
There are many substrings in your input that match this (the bold one is the first):
"Y
zsddfxdfsW.am i .
dddfdfd is though tesing program. Getting Ok Thank YOU. This dog is very friendly."