vendion wrote:
Hello I am having trouble finding the correct syntax for reading a
list of numbers from a file, it is open and can read from it, I tried
with
while (<INPUT>) {
        chomp;
        @some_array = $_;
        print "@some_array\n";
}

my @some_array;
while ( <INPUT> ) {
    chomp;
    push @some_array, $_;
    }
print "@some_array\n";


and

@some_array = <INPUT>;
print "@some_array\n";

chomp( my @some_array = <INPUT> );
print "@some_array\n";


but in both cases it reads the entire list at once but in both cases
it also looped 21 times,

But, the second example does not loop at all!


the amount of numbers in the list I am
reading from.

Also (this part is off topic) where can I get the server info to post
to this group with a newsgroup reader?

Point your Usenet client at: nntp.perl.org



John
--
Perl isn't a toolbox, but a small machine shop where you
can special-order certain sorts of tools at low cost and
in short order.                            -- Larry Wall

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


Reply via email to