http://qs321.pair.com?node_id=723383

sharan has asked for the wisdom of the Perl Monks concerning the following question:

Hi all, I have to write a prog to read some lines from data
hfkjd process jhk start begin output1 output2 end process scrap hkl process khfk shoot hooter begin output3 end process
i want output as
output1 output2 output3
my code looks like
if (/end process/) {end(); } if (/process/) {if(/begin/) { print $_; }}
But still am not able to get the desired output.. could u please help me... Many thanks in advance.