in reply to Re: a way to do 'sort|uniq'
in thread a way to do 'sort|uniq'

sh1tn - I don't understand how this works:

@_{@telephones}=(),print+join$/,sort{ $a <=> $b }keys%_;

I hope you're not disinclined to explain?

Replies are listed 'Best First'.
Re^3: a way to do 'sort|uniq'
by sh1tn (Priest) on Aug 02, 2005 at 19:12 UTC
    @_{@telephones}=(); # %_ hash from @telephones print+ # print the join $/, # joined with "\n" separator sort{ $a <=> $b }keys%_; # list which comes from %_ keys