kens wrote:

# Or if you must use a counter

my $count = 0;

while ( defined($strA[$count]) )
{
   print "$strA[$count++]\n";
}

for my $count (0 .. $#strA) {
  print "[$count] = $strA[$count]\n";
}

**OR**

my $count = 0;

foreach (@strA) {
  print "[$count] = $strA[$count]\n";
  $count++;
}



Rob

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/


Reply via email to