Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: A little golfing challenge: Replacing letters with numbers

by rsFalse (Hermit)
on Feb 21, 2019 at 17:27 UTC ( #1230317=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    perl -0777 -ne 'print "" . ( join "", "A" .. "Z" ) =~ s/[^$_]/ /gr =~ 
    +s/\B\w+\B/-/gr =~ s/ +//gr'
    
  2. or download this
    A-IK-NP-TVWYZ
    
  3. or download this
    perl -0777 -ne 'print "" . ( join "", "A" .. "Z" ) =~ s/[^$_]/ /gr =~ 
    +s/(?<=\w)\w*(?=\w)/-/gr =~ s/ +/ /gr'
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others examining the Monastery: (4)
As of 2020-11-29 02:55 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?