in reply to Slurping strings from text file and pushing to array?
<> returns a list of lines in list context.
my @content = do { local @ARGV = $file ; <> } ;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Slurping strings from text file and pushing to array?
by Mad_Mac (Beadle) on Jul 01, 2010 at 21:32 UTC | |
by ikegami (Patriarch) on Jul 01, 2010 at 22:02 UTC |