in reply to while reading a file, transfer the same data to two different processes.

You may want to create a couple pipes and then fork. The processes can then communicate back and forth. Have a look at the perldoc for pipe.
  • Comment on Re: while reading a file, transfer the same data to two different processes.