Pam Derks wrote:
> my %all_keys = ();
>
> foreach my $key (keys %hash1) {
> $all_keys{$key} = 1;
> }
>
> foreach my $key (keys %hash2) {
> $all_keys{$key} = 1;
> }
Hi pam,
It strikes me that you are throwing away information here. Even if that information
is not needed in the immediate con
Pam Derks wrote:
>
> Hi all,
Hello,
> I have 2 files that contain a filename and # of hits
> I've split the contents of these 2 files into %hash1 and %hash2
> I want to find out the difference in the # of hits
> can someone shed some light on the approach I should take.
>
> I've gotten this far
-Original Message-
From: Pam Derks [mailto:[EMAIL PROTECTED]]
Sent: Friday, January 31, 2003 3:21 PM
To: [EMAIL PROTECTED]
Subject: newbie stuck in a hash
Hi all,
I have 2 files that contain a filename and # of hits
I've split the contents of these 2 files into %hash1 and %hash2
I wan
Pam Derks wrote:
> Hi all,
>
> I have 2 files that contain a filename and # of hits
> I've split the contents of these 2 files into %hash1 and %hash2
>
> I want to find out the difference in the # of hits
>
> can someone shed some light on the approach I should take.
>
> thanks in advance,
> Pa
quot; sign
print "$page $diff\n";
}
It can be done a lot more compact than this, but I thought this would be a
bit more understandable.
Rob
-Original Message-
From: Pam Derks [mailto:[EMAIL PROTECTED]]
Sent: Friday, January 31, 2003 3:21 PM
To: [EMAIL PROTECTED]
Subject: newbie
Hi all,
I have 2 files that contain a filename and # of hits
I've split the contents of these 2 files into %hash1 and %hash2
I want to find out the difference in the # of hits
can someone shed some light on the approach I should take.
thanks in advance,
Pam
I've gotten this far:
sample data