Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re^2: Printing keys from a hash by value?

by jms53 (Monk)
on Jan 30, 2012 at 16:38 UTC ( #950801=note: print w/ replies, xml ) Need Help??


in reply to Re: Printing keys from a hash by value?
in thread Printing keys from a hash by value?

That is very interesting. I can surely use this to benchmark the different algorithms.

However, could you enlighten me on how the first part works? perldoc has nothing on chr... Thanks!


Comment on Re^2: Printing keys from a hash by value?
Re^3: Printing keys from a hash by value?
by Anonymous Monk on Jan 30, 2012 at 19:49 UTC
Re^3: Printing keys from a hash by value?
by aaron_baugher (Deacon) on Jan 30, 2012 at 20:53 UTC

    chr gives the character corresponding to an ASCII value. 65 = 'A', 66 = 'B', and so on. In retrospect, I could have made my loop 65..90, but I think 1..26 makes it more obvious that I'm spanning the alphabet. Putting x4 after it just turns 'A' into 'AAAA' and so on, to make it more obvious that they're words.

    Aaron B.
    My Woefully Neglected Blog, where I occasionally mention Perl.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (13)
As of 2014-12-29 16:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (193 votes), past polls