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

Re (tilly) 4 (y): Fore!!! (was The Perl Review)

by tilly (Archbishop)
on Feb 02, 2002 at 14:54 UTC ( [id://142918]=note: print w/replies, xml ) Need Help??


in reply to Re: Re (tilly) 2: Fore!!! (was The Perl Review)
in thread The Perl Review

y is a function which is explained in perlop. What it does is substitutes for any character in one list, the corresponding charater on another list.

What I did was use ord and chr to figure out what the ASCII representation of 9 was, and what came right after that. Then I used tr to move the range A-Z so that they came right after the range 0-9, so that I could convert any digit into a number just by taking ord and subtracting off the ord of 0.

  • Comment on Re (tilly) 4 (y): Fore!!! (was The Perl Review)

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others lurking in the Monastery: (9)
As of 2024-04-19 09:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found