exfacior has asked for the wisdom of the Perl Monks concerning the following question:
but was wondering if it were possible to assign all the lines to an array just as easily.open (FILE,"filepath") || die "Can't open file"; chomp ( my ( $var1 , $var2 , $var3 ) = <FILE> ); close (FILE)
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Making an array out of each line in a file
by TedYoung (Deacon) on Nov 11, 2004 at 21:54 UTC | |
by tachyon (Chancellor) on Nov 11, 2004 at 22:28 UTC | |
Re: Making an array out of each line in a file
by atcroft (Abbot) on Nov 11, 2004 at 21:56 UTC | |
Re: Making an array out of each line in a file
by pg (Canon) on Nov 11, 2004 at 22:13 UTC | |
Re: Making an array out of each line in a file
by FoxtrotUniform (Prior) on Nov 11, 2004 at 21:58 UTC | |
by PerlingTheUK (Hermit) on Nov 11, 2004 at 22:34 UTC | |
by FoxtrotUniform (Prior) on Nov 11, 2004 at 22:42 UTC | |
by Fletch (Bishop) on Nov 12, 2004 at 00:50 UTC | |
by tilly (Archbishop) on Nov 12, 2004 at 02:34 UTC | |
by PerlingTheUK (Hermit) on Nov 11, 2004 at 23:09 UTC | |
by chb (Deacon) on Nov 12, 2004 at 08:39 UTC |