title: How can I create a two-dimensional array in Perl?
body: <p>I am currently trying to pass a 32 by 48 matrix file to a multi-dimensional array in Perl. I am able to access all of the values, but I am having issues accessing a specific value.</p>
  <p>Here is a link to the data set:
  <a href="http://paste-it.net/public/x1d5301/" rel="nofollow noreferrer">http://paste-it.net/public/x1d5301/</a></p>
  <p>Here is what I have for code right now.</p>
  <pre><code>#!/usr/bin/perl
  
  open FILE, &quot;testset.txt&quot; or die $!;
  my @lines = &lt;FILE&gt;;
  
  my $size = scalar @lines;
  
  my @matrix = (1 .. 32);
  my $i = 0;
  my $j = 0;
  my @micro;
  
  foreach ($matrix)
  {
      foreach ($lines)
      {
          push @{$micro[$matrix]}, $lines;
      }
  }
  </code></pre>