Help for this page
use Regexp::Assemble; my $ra = Regexp::Assemble->new; ... s/$re//gsi; # this will replace # foreach (@words) { ... s/// ... } # and do the word deletion in one go