... unless $seen{$item}++ notation:
%seen = ();
foreach $item (genlist()) {
func($item) unless $seen{$item}++;
}
Forward to Use Hashes of Records, not Parallel Arrays
Back to Use Hashes for Sets
Up to index
Copyright © 1998, Tom Christiansen
All rights reserved.