Tim Hammerquist wrote:
>
> "Elston, Jeremy" wrote:
> >
> > Greetings...
> >
> > Peter's solution is the one I would recommend unless you are reading large
> > files and/or your system has little memory available. By reading into an
> > array, the entire file will be pulled into memory. If memor
"Elston, Jeremy" wrote:
>
> Greetings...
>
> Peter's solution is the one I would recommend unless you are reading large
> files and/or your system has little memory available. By reading into an
> array, the entire file will be pulled into memory. If memory use is an
> issue, you could use som
Greetings...
Peter's solution is the one I would recommend unless you are reading large
files and/or your system has little memory available. By reading into an
array, the entire file will be pulled into memory. If memory use is an
issue, you could use something like this:
-
open(FILE, "m
-start-
> "Ricardo Cumberbatch L." <[EMAIL PROTECTED]>
>at02/15/2001 08:24 AM
>Hi every one I had to do a perl script but a need to know how in perl you
>do to read the last line in a file, I no to read in a file but how to
read
>every time a need the last line in a file.
Probably the bes
There may be a better way, but this should work (untested):
open(FILE,"$thefile") || die "Can't open $thefile: $!\n";
@file=;
close(FILE);
$lastline=pop(@file);
-Original Message-
From: Ricardo Cumberbatch L. [mailto:[EMAIL PROTECTED]]
Sent: Thursday, February 15, 2001 9:24 AM
To: Perl