Beefy Boxes and Bandwidth Generously Provided by pair Networks DiBona
go ahead... be a heretic
 
PerlMonks  

Re: Re: Hash Variable

by qball (Beadle)
on Apr 05, 2001 at 21:13 UTC ( [id://70297]=note: print w/replies, xml ) Need Help??

This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.


in reply to Re: Hash Variable
in thread Hash Variable

I see where you're creating hash:
$hash{$vars[2]} = join(' ', @vars[0,1,3]);
How would I print that out?
foreach $var2 (keys %hash){ print "value: $hash{$var2}\n"; }
...doesn't work too well.

qball~"I have node idea?!"

Replies are listed 'Best First'.
Re: Re: Re: Hash Variable
by how do i know if the string is regular expression (Initiate) on Apr 05, 2001 at 22:11 UTC
    What do you mean "doesn't work too well"? That should work.
    Is an error occuring, is there not output, or is it not the way you want it to look?

    - FrankG

      It's not printing unique values. However, it is printing "key ' ' already exists in hash" after each line.

      So basically it's printing all the rows even those with $var2 that aren't unique.

      qball~"I have node idea?!"

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://70297]
help
Sections?
Information?
Find Nodes?
Leftovers?
    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.