![]() |
|
Don't ask to ask, just ask | |
PerlMonks |
Re: doubt in storing a data of 2 lines in an array.by davorg (Chancellor) |
on Oct 30, 2006 at 13:42 UTC ( #581289=note: print w/replies, xml ) | Need Help?? |
You are reading the file a line at a time. So when you process the TITLE line, the data in $_ only contains the line that begins with TITLE. So that is all that ends up in $title. The rest of the TITLE data is processed on the next iteration of the loop (and, probably ends up as the first element in @se). There are a couple of ways to solve this:
-- <http://dave.org.uk> "The first rule of Perl club is you do not talk about
Perl club."
In Section
Seekers of Perl Wisdom
|
|