in reply to I/O functions

For the first question, it's a FAQ, so you should probably start by reading (or at least skimming) the entire FAQ, either on your local disk by typing perldoc perlfaq or at the Monestary via perlman:perlfaq.

As for the second, if you have to ask, you should still be using read(). {grin} But the answer to that is once again in the docs in perlman:perlfunc.

-- Randal L. Schwartz, Perl hacker