
Hi Jason, I was just reading this and it seems to overlap with: http://www.python.org/peps/pep-0218.html I.E. uniq is equivalent to union (with self). wrt to the uniq command line tool, if you've 2 files a & b, then: uniq a b = union uniq -u a b = difference uniq -d a b = intersection So uniq really is a set operation and if Python had a set builtin type then I'm not sure a uniq method would be required? Perhaps the list object could support the union operator so to uniqify a list you could do: mylist |= mylist cheers, Pádraig.

Padraig> So uniq really is a set operation and if Python had a set Padraig> builtin type then I'm not sure a uniq method would be required? There's a sets.py module in the CVS repository. (new w/ 2.3.) -- Skip Montanaro - skip@pobox.com http://www.mojam.com/ http://www.musi-cal.com/

Padraig> So uniq really is a set operation and if Python had a set Padraig> builtin type then I'm not sure a uniq method would be required? There's a sets.py module in the CVS repository. (new w/ 2.3.) -- Skip Montanaro - skip@pobox.com http://www.mojam.com/ http://www.musi-cal.com/
participants (3)
-
jason petrone
-
Padraig Brady
-
Skip Montanaro