in reply to
Determining if an element is already in an array.
You can use the grep function: push(@foo,$elm) unless grep(/$elm/,@foo); Creating a hashtable every time you're tring to test for an element may be alot of overhead (memory and CPU).
Comment on
Re: Determining if an element is already in an array.
In Section
Seekers of Perl Wisdom