Think about Loose Coupling | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
I just want to mention, since it sounds like you are a beginner in Perl, that the method given by ysth will overwrite the contents of your file. If you want to append to a file, you need to open the file as
open my $handle, ">> filename" or die "Couldn't open file: $!"; Note the ">>" instead of ">". You can print anything else to the file using
until the close command is executed on $handle. In reply to Re: Output to file question
by swkronenfeld
|
|