in reply to Trouble grepping values when hash contains multiple values per key
This will fail silently, because of operator precedence. Use "or" instead of "||".open CONFIG, "$hol_file" || die "Cannot open log for writing. $!";
Best practices say you should use the 3-parameter form of "open", and local file handles, so your code should read:
open (my $config , "<", "$hol_file") or die "Cannot open '$hol_file': +$!";
Syntactic sugar causes cancer of the semicolon. --Alan Perlis
|
|---|