Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re^2: Interesting line which I read from Monk's snippets

by pKai (Priest)
on Jan 31, 2006 at 08:30 UTC ( #526685=note: print w/ replies, xml ) Need Help??


in reply to Re: Interesting line which I read from Monk's snippets
in thread Interesting line which I read from Monk's snippets

To deliver the same result (i. e. undef) for not found input values, the tr solution has to be a bit more elaborate.

Somewhat along the line of

my $found = (my $pat = substr($0,0,1)) =~ tr/abcd/-=~^/; $pat = $found ? $pat : undef;


Comment on Re^2: Interesting line which I read from Monk's snippets
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (6)
As of 2014-09-20 08:12 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (157 votes), past polls