Question on lists

Alan G Isaac aisaac at american.edu
Thu Jul 29 10:46:18 EDT 2004


"Heiko Wundram" <heikowu at ceosg.de> wrote in message
news:mailman.866.1090988681.5135.python-list at python.org...
> >>> import sets
> >>> list(sets.Set(['a','a','b','b','d','b','c','a','ladida']))
> ['a', 'c', 'b', 'd', 'ladida']


Newbie question:
OK, this is great.  But I was not aware of this module,
and I was working in my own sets.py.
So how do I handle this namespace issue?
I.e., how can I 'import sets' and get the Python module,
when my own script is named sets.py?

Thanks,
Alan Isaac






More information about the Python-list mailing list