On Fri, 30 Aug 2002, Ramprasad A Padmanabhan wrote: > Hi All, > I have been using perl on linux for quiet some time now and I have > found that Perl does not work the same in windows > > eg. To get all the unique elements of an array in linux I use a > simple one liner > > @unique = grep{!/$seen{$_}++/} @all_elements;
This will not work even on linux. Why do you need to do a pattern match anyways? Just a @unique = grep{!$seen{$_}} @all_elements; should do -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]