in reply to A another tr/// statement question..in thread tr/// statement
my $letters = "abcwxy"; my $re = qr/[$letters]/; my $cnt; while (<INPUT>) $cnt++ while /$re/g; } print "$cnt\n"; [download]