in reply to Re^4: Retrieving Key and Value Hashes
in thread Retrieving Key and Value Hashes

Unless I missed something, your revised script (based on Anonymous Monk's suggestion) should work with the data you've shown. If it does not print anything, then, probably, the data is not exactly what you think.

I would suggest that you add some debugging statements to the first part of your script, for example as follows:

use Data::Dumper; open(FILE1, $ARGV[0]) or die "Cannot open the file: $!"; my %hash1 = split ' ', do{ local $/; <FILE1> }; close FILE1; print Dumper \%hash1;
and provide the printed output (or part thereof if it is large).

Update: Fixed a typo in the code above. Thanks to AnomalousMonk for having picked it and informed me.