in reply to Re^2: lsearch for perl?
in thread lsearch for perl?
While I agree that hashes wouldn't be too useful here (being unordered), I think of hashes as having three basic uses (not one):
my %user_passwds = ( joe => ..., jeff => ..., john => ..., );
my %user = ( id => 'joe', name => 'Joe', passwd => ..., home_dir => ..., );
my %unique; ++$unique{$_} foreach @list; @list = keys %unique;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: lsearch for perl?
by thor (Priest) on Dec 05, 2005 at 19:40 UTC | |
by ikegami (Patriarch) on Dec 05, 2005 at 19:44 UTC |