in reply to quandery about a grep statement
Perhaps I fail to understand exactly what you are doing, but doesn't this accomplish your goal?
sub beautify { my %seen; return sort {$a<=>$b} grep {!$seen{$_}++} @_; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: quandery about a grep statement
by jynx (Priest) on Mar 29, 2001 at 05:28 UTC | |
by extremely (Priest) on Mar 30, 2001 at 02:21 UTC |