in reply to Counting elements in array and outputing the count and item

Sorry, I saved only half of the answer.

To do it in Perl I would try:

my %statuscount; foreach my $stat (@status) { $statuscount{$status}++; }

Careful with that hash Eugene.