http://www.perlmonks.org?node_id=294449

Q&A > files > Is it possible to write to 2 files, eg. print LOGFILE,TEMP 'hello'? - Answer contributed by belg4mit

IO::Tee

  • Comment on Answer: Is it possible to write to 2 files, eg. print LOGFILE,TEMP 'hello'?
Replies are listed 'Best First'.
Re: Answer: Is it possible to write to 2 files, eg. print LOGFILE,TEMP 'hello'?
by princepawn (Parson) on Sep 26, 2003 at 18:11 UTC
    how about
    print $_ "hello" for (\*TEMP, \*LOGFILE);

    Carter's compass: I know I'm on the right track when by deleting something, I'm adding functionality.