On Fri, 22 Oct 2004 02:05:33 -0700 (PDT)
Melis Mutlu <[EMAIL PROTECTED]> wrote:

> Hi,
> 
> I would like to write a whole string into a file with
> the following code: 
> 
> open(NEW, "new.txt") or die "cannot open new_acl.txt";
> open(OUT, ">test");
> while(my $line=<NEW>) {
>                         chop $line;
>                         $string=$string.$line;
>                         print OUT $string}
> 

what happens if you try

while(<NEW>) {
  chomp;
  print OUT "$_ "}#presuming you want a space between them



Owen
 

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to