DB<130> $a='ABCBBBCBADBCCACDDDAC' => "ABCBBBCBADBCCACDDDAC" DB<131> grep { /(.)\1\1/ } unpack '(A5)4', $a => "DDDAC"
unpack pattern shortened
Cheers Rolf
( addicted to the Perl Programming Language)
IMHO its also possible to include the same principle into one regex (matching groups of 5 characters and investigating each match with embedded Perl) but I doubt it's more readable.
In reply to Re: Regex matching on grid alignment
by LanX
in thread Regex matching on grid alignment
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |