in reply to Matching Words

How about:
while (<>) { s/^\s*//; printf("%s %s\n",map{s/\W\B//;s/\B\W//;$_}(split(/\s+/,$_))[0,-1]); }
UPDATE - had to add line to remove leading space ... tsk tsk

jeffa

L-LL-L--L-LL-L--L-LL-L--
-R--R-RR-R--R-RR-R--R-RR
B--B--B--B--B--B--B--B--
H---H---H---H---H---H---
(the triplet paradiddle with high-hat)