use strict; use warnings; my $n = 3; # number of adjacent characters $n--; $_ = 'testing 1234567 ........ aaaaaaaasssssss __________ ++++++++++ - +-------- testing testing '; s/((.)\2{$n})\2*/$1/g; print;
In reply to Re^2: Supress similar chars in the string
by toolic
in thread Supress similar chars in the string
by Lana
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |