in reply to Having repeated intances become one in Array

#!/usr/bin/perl my @array = qw[ foo bar baz bar foo baz baz bad ]; sub dedupe { ${_}=do{{},[],{}};@{${_}}{@_,%_,@_}=$|;keys%{\%{${_}}} } print dedupe(@array);

Replies are listed 'Best First'.
Re: Re: Having repeated intances become one in Array
by Anonymous Monk on Aug 09, 2002 at 22:47 UTC
    i'm just a novice in perl...could you please explain how your code works ? i'm sure i could learn a lot from your code thanks :-)