See Files and I/O in perlintro.
In reply to Re^3: Filtering Output from two files by hippo in thread Filtering Output from two files by vighneshmufc