title: How can I replace a single space in every entry of an aray with a tab using Perl? Can I use sed-like commands?
body: <p>I have an array with several values in the format "xxxxx yyyyyy" at each index.  I want to traverse the array and replace the single place with a tab.  I know I could parse an output file with sed using the substitute command <code>s/ /\t/</code>.  Can I do something similar in perl while using a for loop to iterate through the array and re-write each index?</p>
  
  <pre><code>#!/usr/bin/perl -w
  
  foreach my $arg (@ARGV) {
  #print $arg . "\n";
  push (@md5, `md5sum $arg`);
  }
  
  foreach $entry (@md5) {
  $entry = s/ /\t/;
  print $entry . "\n";
  }
  </code></pre>
  
  <p><strong>OUTPUT</strong></p>
  
  <pre><code>Use of uninitialized value $_ in substitution (s///) at ./mymd5.pl line 9.
  
  Use of uninitialized value $_ in substitution (s///) at ./mymd5.pl line 9.
  
  Use of uninitialized value $_ in substitution (s///) at ./mymd5.pl line 9.
  
  Use of uninitialized value $_ in substitution (s///) at ./mymd5.pl line 9.
  
  Use of uninitialized value $_ in substitution (s///) at ./mymd5.pl line 9.
  
  Use of uninitialized value $_ in substitution (s///) at ./mymd5.pl line 9.
  
  Use of uninitialized value $_ in substitution (s///) at ./mymd5.pl line 9.
  
  Use of uninitialized value $_ in substitution (s///) at ./mymd5.pl line 9.
  </code></pre>