in reply to Looping through a hash where some keys are the same

I almost spit out my water when I read this line from your first code block:
my $value = $shit{$key};
From a purely social point of view, it's probably bad form to use dirty language in a computer program. Just doesn't look professional ;-)

From a code point of view, trying to retrieve a value from one hash with a key from another is also bad form, and might have something to do with your problematic output.

Replies are listed 'Best First'.
Re^2: Looping through a hash where some keys are the same
by GaijinPunch (Pilgrim) on Feb 18, 2005 at 04:59 UTC
    Oops... how'd that get in there? Errr... yeah, my hash in my original test was named that. As for professional.... it was a 5 line script, and not related to work, so I'm not really going to lose too much sleep over it. Apologies if I offended anyone here though.