Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re^2: Fastest split possible

by AnomalousMonk (Archbishop)
on Nov 06, 2019 at 20:37 UTC ( [id://11108404]=note: print w/replies, xml ) Need Help??


in reply to Re: Fastest split possible
in thread Fastest split possible

That's simpler and probably faster than what I had in mind here. Combined with an idea from Discipulus:

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<


Give a man a fish:  <%-{-{-{-<

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11108404]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others chanting in the Monastery: (7)
As of 2024-04-25 11:26 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found