Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister

Re^5: Problems with Hash Keys and Spaces

by tptass (Sexton)
on Aug 08, 2008 at 17:04 UTC ( #703164=note: print w/replies, xml ) Need Help??

in reply to Re^4: Problems with Hash Keys and Spaces
in thread Problems with Hash Keys and Spaces

You should try creating another array with just 'Test MMA' in it and give it a try. Or perhaps, you could just try copying the following into a new file and test to see if it works. If it does than you know something is wrong with your array definition.

my $array = ['','Test MMA','Generic key']; my %hash = ( "Common SW Component" => "4885", "Test MMA" => "5130", "Generic key" => "5033", "Another generic key" => "4575", ); my $variable = "@$array[1]"; print "$hash{$variable}\n";

Log In?

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

How do I use this?Last hourOther CB clients
Other Users?
Others taking refuge in the Monastery: (6)
As of 2023-12-05 22:50 GMT
Find Nodes?
    Voting Booth?
    What's your preferred 'use VERSION' for new CPAN modules in 2023?

    Results (29 votes). Check out past polls.