in reply to Help to identify Error in my program

Please read some of the links that are provided below the text entry box when you are composing a post; learn to use the "code tags" (<code> or <c>), placing them only around your code snippets, not around your entire post. Please do not use <pre> tags at all.

If you are going to present us with error messages that include line numbers, you should indicate in your code which lines those numbers represent. I'm guessing that the two messages you quoted -- which are actually warnings (not errors) -- refer to the two lines marked below:

my $one_number = $numbers[$hashtable{$name} - 1]; # line 24 if ( $one_number >= 20 ) { print "$name $hashtable{$name} $one_number\n"; # line 26 }
This would suggest that those messages resulted from an iteration of your while <FD> loop in which the variable "$name" was set to a value that happened to be non-existent as a key in "%hashtable". If you change your test condition from this:
next if ! s{ \A (\S+) \s+ (?= \d ) }{}xms;
to something like this instead:
next unless ( s{ \A (\S+) \s+ (?= \d ) }{}xms and exists( $hashtab +le{$1} ));
then the warnings should go away (and you might end up with fewer lines of printed output).

Replies are listed 'Best First'.
A reply falls below the community's threshold of quality. You may see it by logging in.