I am just now learning perl.  I have written a program that ought to simply read a 
file a write its contents to another file.  However, I get the following message:

"Syntax error at perl.txt line 8, near "$x".
 Execution of perl.txt aborted due to compilation errors."

Here is the code:

#!/usr/bin/perl
open(INFILE, "testin");
open(OUTFILE, ">testout");

$x=getc(INFILE);
while($x!=eof(INFILE){
   print ("$x");
   $x=getc(INFILE);
}
close(INFILE);
close(OUTFILE);


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to