title: Perl map - need to map an array into a hash as arrayelement->array_index
body: <p>I have a array like this:</p>
  
  <pre><code>my @arr = ("Field3","Field1","Field2","Field5","Field4");
  </code></pre>
  
  <p>Now i use map like below , where <strong>/DOSOMETHING/</strong> is the answer am seeking.</p>
  
  <pre><code>my %hash = map {$_ =&gt; **/DOSOMETHING/** } @arr
  </code></pre>
  
  <p>Now I require the hash to look like below:</p>
  
  <pre>
  Field3 => 0
  Field1 => 1
  Field2 => 2
  Field5 => 3
  Field4 => 4
  </pre>
  
  <p>Any help?</p>