in reply to Re: Re: Re: Using a Sub to pull info. from a Text File
in thread Using a Sub to pull info. from a Text File

Just to add to this, the other thing you could do instead of looking for a blank line, is to just read in the next two lines after linescore. Basically..

my $ls = 0; while (<SCORES>) { if (/^LINESCORE/) { $ls++; } #linescore is greater than 1(we found LINESCORE) and less than 3(we +haven't read 2 lines yet) elsif ($ls && $ls < 3) { chomp; push @line, $_; $ls++ } }

Hope this helps..
Rich