in reply to get the line of ith occurrence of '>' without OPENING THE FILE
Now $bigline will contain everything up to the 10000th '>'. I'm not sure that this will work if you've been having file troubles, but it's probably worth a try.my $big_line = "" # Set the newline character to '>' $/ = '>'; open fh, $filename; for (my $i = 0; i < 10000; i++) { $big_line .= <fh>; } $/ = "\n"; close fh;
|
|---|