> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, August 09, 2001 10:33 AM
> To: [EMAIL PROTECTED]
> Subject: compilation error - simple program
>
>
> I am just now learning perl. I have written a program that
> ou
On Thursday 09 August 2001 10:32, [EMAIL PROTECTED] wrote:
> "Syntax error at perl.txt line 8, near "$x".
> Execution of perl.txt aborted due to compilation errors."
>
> $x=getc(INFILE);
> while($x!=eof(INFILE){
You'e missing a closing paren here.
However, even when I fix that this doesn't seem
> #!/usr/bin/perl
> open(INFILE, "testin");
> open(OUTFILE, ">testout");
>
> $x=getc(INFILE);
> while($x!=eof(INFILE){
^
You have mismatched parentheses here. Should be:
while ($x!=eof(INFILE)){
>print ("$x");
>$x=getc(INFILE);
> }
> close(INFILE);
> close(OUTFILE
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/