I didn't comment on this section before since the program seems to have had very little effort put into it. The last if !line; part will never do anything even if corrected since $line is only declared and assigned a value if the regex matches.
my $line = $_ if /\bWood\b/; chomp ($line); last if !line;
Perhaps something like last if /^\s*$/ placed ahead of the my $line = $_ ... would work.
In reply to Re^2: Print hash keys and lookup the keys for values in another filr
by Lotus1
in thread Print hash keys and lookup the keys for values in another filr
by Magnolia25
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |