in reply to Replicate file

You are getting the spaces because you are stringifying the array. Try
foreach my $file (@filenames) { open (INFILE, "$file") || die ("Can't open file $file$!"); @all=<INFILE>; close (INFILE); print OUTFILE1 @all; }
or better yet
foreach my $file (@filenames) { open (INFILE, "$file") || die ("Can't open file $file$!"); print OUTFILE1 <INFILE>; close (INFILE); }

-Mark

Replies are listed 'Best First'.
Re: Re: Replicate file
by Anonymous Monk on Apr 13, 2004 at 22:50 UTC
    Thank you very much!! It works, the only think it is leaving a blank line at the end of the file