Used the following:# input phn .. .. # 1ord
But this prints out the first finding of phna_ through to first 1ord. 5 lines separate these patterns in the text file Tried this also, but this seems to starts printing from a poisiton i dont expect it to:if (/phn_a/ ... /1ord/) { print OUT $_; }
$nLines = 5 if ( /1ord$/ ); print OUT if $nLines-- > 0;
In reply to extracting lines by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |