Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re: The Perl Review

by Anonymous Monk
on Feb 01, 2002 at 22:11 UTC ( #142787=note: print w/ replies, xml ) Need Help??


in reply to The Perl Review

My first golf attempt (the base 36 question above).. any inspirational thoughts/comments?

$_="asd123"; print eval join"+",map{$_=(-54+ord uc);$_+=6if/-/;"$_*36**".$i++}rever +se split('');


Comment on Re: The Perl Review
Download Code
Replies are listed 'Best First'.
Re: Re: The Perl Review
by blakem (Monsignor) on Feb 01, 2002 at 22:21 UTC
    Two quick comments. Your values are off by one 'A' => 11 instead of 10. Also split('') is shorter as /./g

    Other than that, I like it... eval entries are always cool.

    -Blake

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (14)
As of 2015-07-31 21:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (282 votes), past polls