[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

RE: [MacPerl] perl to c/c+/



That is neither. It displays both unique _and_ repeated
entries, but each only once. It also provides a count of
the number of times the entry was seen.

----------
From: 	J. Linder
Subject: 	Re: [MacPerl] perl to c/c+/

>First, from the camel book there is the classic one line which
>creates an array and removes all unique entries.
>
>   while (<>) { $seen{$_}++; }  # only see what is not seen
>
>This is blazingly fast.
>

Does it remove all unique entries, or ensure that entries in the $seen{}
array are unique?  ie, does it uniq -d or uniq -u????

Thanks


***** Want to unsubscribe from this list?
***** Send mail with body "unsubscribe" to mac-perl-request@iis.ee.ethz.ch