use File::Slurp; my @array = read_file('filename.txt'); [download]
That's all there is to it.
In reply to Re: reading file into an array by meetraz in thread reading file into an array by Anonymous Monk