Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re^2: a hash and 2 loops--not working

by frozenwithjoy (Curate)
on Nov 09, 2012 at 00:04 UTC ( #1003030=note: print w/ replies, xml ) Need Help??


in reply to Re: a hash and 2 loops--not working
in thread a hash and 2 loops--not working

I like this; however, USD isn't working for me (presumably because of the lc in validate => sub { return exists $curr->{lc shift}; },

Edit: I fixed it by changing that line to:

validate => sub { my $chosen_curr = shift; return exists $curr->{$cho +sen_curr}; },

And by removing lc from return lc $in;


Comment on Re^2: a hash and 2 loops--not working
Select or Download Code
Re^3: a hash and 2 loops--not working
by davido (Archbishop) on Nov 09, 2012 at 00:16 UTC

    Good call. :) It might be better to just change the hash so that all the keys are lower cased. I'll update.


    Dave

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (8)
As of 2015-07-06 05:56 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 (70 votes), past polls