in reply to Re^2: from txt file to array
in thread from txt file to array
But here my taste would be a more functional idiom:my @myarray; while (my $item = <DATA>) { chomp $item; push @myarray, $item; }
my @myarray = map { chomp; $_ } <DATA>;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: from txt file to array
by karlgoethebier (Abbot) on Jun 22, 2017 at 08:36 UTC |