Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

wfsp's scratchpad

by wfsp (Abbot)
on Aug 30, 2004 at 15:30 UTC ( #386935=scratchpad: print w/replies, xml ) Need Help??

my $find = q{something}; for my $key (%hash){ for my $element (@{$hash{$key}}){ if ($element eq $find){ print qq{found $find}; endif } }
my $key = q{key}; my $find = q{something}; my @found = grep{$_ eq $find} @{$hash{$key}}; print qq{@found\n};