Help With EOF character and regular expression matching: URGENT

Jeff Epler jepler at unpythonic.net
Mon Feb 23 02:33:27 CET 2004


On Sun, Feb 22, 2004 at 05:17:50PM -0800, Eric @ Zomething wrote:
> Also, maybe this will help with dups:

If you're using python2.3, you want to use sets for this.

>>> import sets
>>> l = [1, 1, 2, 3, 5, 5, 9]
>>> sets.Set(l)
Set([1, 2, 3, 5, 9])
>>> list(sets.Set(l))
[1, 2, 3, 5, 9]

Jeff




More information about the Python-list mailing list