c:\@Work\Perl\monks>perl -wMstrict -le "my $consonants = qr{ [^aeiouAEIOU]+ }xms; ;; my $s = qq{four score\nand seven\nyears ago\nour fathers\n}; print qq{>$s<}; ;; open my $fh, '<', \$s or die qq{opening in-memory: $!}; ;; process() while <$fh>; ;; sub process { chomp; s{ ($consonants) }{\U$1}xmsg; print qq{>$_<}; } " >four score and seven years ago our fathers < >FouR SCoRe< >aND SeVeN< >YeaRS aGo< >ouR FaTHeRS<