in reply to How can I count and display unique items in an array? (was: array counting)

@a = qw/foo bar foo baz bar qux foo/; $hash{$_}++ foreach @a;
The counts are in %hash now. HTH.

--

There are 10 kinds of people -- those that understand binary, and those that don't.