You said:
my $keys = {};
while (<FILEHANDLE>) {chomp; $keys[$_] = 1;}
$keys is not an array, you've defined it as a hash reference. You meant $keys->{$_} ....
Then you said:
exists($keys, $recordArray[2])
exists() does not work like that.
exists $keys->{$recordArray[2]};
Please, if you don't test the code you supply, acknowledge that in writing. | [reply] [d/l] [select] |
| [reply] |
"...my approach to this problem..."
"One Step Forward, Two Steps Back" (Vladimir Ilyich Lenin)
See also
«The Crux of the Biscuit is the Apostrophe»
perl -MCrypt::CBC -E 'say Crypt::CBC->new(-key=>'kgb',-cipher=>"Blowfish")->decrypt_hex($ENV{KARL});'Help
| [reply] [d/l] |