#!perl use warnings; use strict; my $r = 0 while (<DATA>) { $r++ if $r; if (/start/) { $r = 1; print "Start storing...\n"; } $r = 0 if (/end/); next unless $r; print; } __DATA__ predata more predata start real data more real data end post data post data
In reply to Re: match and read
by tweetiepooh
in thread match and read
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |