Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re: The Perl Review

by petral (Curate)
on Feb 04, 2002 at 18:34 UTC ( #143274=note: print w/ replies, xml ) Need Help??


in reply to The Perl Review

Here's another similar one:
$b=$b*36-48-7*/\D/+ord for pop=~/./g; print$b,$/
36 or 47 chars depending on how you count. Another WTDI using recursion:
sub x{ $_&&-7*/\D$/+ord(chop)-48+36*&x } $_=pop; print x,$/
which is 31 chars inside the sub and 55 chars total.

  p

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (10)
As of 2016-08-24 07:54 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    The best thing I ever won in a lottery was:















    Results (338 votes). Check out past polls.