in reply to Replicate file
Are you sure you want to exit your program if one of the files can't be opened? I might have written it something like this:
for my $file (@filenames) { open IN,$file or warn("unable to open $file - $!\n"), next; print OUT <IN>; close IN; }
You'll also notice that I didn't quote the filename. No need for that
|
|---|