Chris San wrote:
It is supose this code prints the first line of file text.txt (which
is not empty), but it doesn't print anything.
$file = "text.txt";
open (file);
;
The above statement does not store the result in $_, this is special
only inside a while statement
while () is equivalent t
From: Chris San [mailto:[EMAIL PROTECTED]
Sent: Tuesday, June 24, 2003 11:25 PM
To: [EMAIL PROTECTED]
Subject: Simple doublt of $_ and print;
It is supose this code prints the first line of file text.txt (which is
not empty), but it doesn't print anything.
$file = "text.txt";
open (fil
It is supose this code prints the first line of file text.txt (which is
not empty), but it doesn't print anything.
$file = "text.txt";
open (file);
;
print;
close (file);
I understood that ; gets a line (the first in this case) and, in
this case, it puts the line in $_ . Also, print; (witho