in reply to How to match the sequences with headers
while (<IFILE>) { chomp; if ($_ =~ /sequence/){ @headerseq = split('\n',$_);
You don't show where you have set $/ to some kind of record seperator so you are reading in one line at a time. That means split('\n',$_) will return one element, the whole line. Each time you are setting @headerseq to the line that matches /sequence/.
The same applies to the other arrays. You are not actually using them as arrays since they only ever hold one element in this setup.
|
|---|