![]() |
|
We don't bite newbies here... much | |
PerlMonks |
Re: pattern matching to seperate databy snopal (Pilgrim) |
on May 03, 2009 at 13:43 UTC ( #761580=note: print w/replies, xml ) | Need Help?? |
This looks like homework to me so I'll make suggestions rather than code
1) Filehandles can be stored in variables too:
2) Read every line - print every line. You are obviously not doing that. 3) set another Filehandle var '$fh' with the appropriate Filehandle as you detect a change and use your new $fh to store and print to the right file.
In Section
Seekers of Perl Wisdom
|
|