Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #5391
| Path | csiph.com!x330-a1.tempe.blueboxinc.net!feeder1.hal-mli.net!news.glorb.com!news.astraweb.com!border5.newsrouter.astraweb.com!not-for-mail |
|---|---|
| From | Ben Finney <ben+python@benfinney.id.au> |
| Newsgroups | comp.lang.python |
| Subject | Re: Converting a set into list |
| References | <iqlgj4$iet$1@speranza.aioe.org> <87iptdid68.fsf@benfinney.id.au> <iqm4tk$3sl$1@speranza.aioe.org> |
| X-Public-Key-ID | 0xAC128405 |
| X-Public-Key-Fingerprint | 517C F14B B2F3 98B0 CB35 4855 B8B2 4C06 AC12 8405 |
| X-Public-Key-URL | http://www.benfinney.id.au/contact/bfinney-pubkey.asc |
| X-Post-From | Ben Finney <bignose+hates-spam@benfinney.id.au> |
| Date | Sun, 15 May 2011 09:21:38 +1000 |
| Message-ID | <871v00j2bh.fsf@benfinney.id.au> (permalink) |
| User-Agent | Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux) |
| Cancel-Lock | sha1:br2xMFRvRFwES+MFPmw42BQTxAs= |
| MIME-Version | 1.0 |
| Content-Type | text/plain; charset=utf-8 |
| Content-Transfer-Encoding | 8bit |
| Lines | 20 |
| Organization | Unlimited download news at news.astraweb.com |
| NNTP-Posting-Host | 6714654b.news.astraweb.com |
| X-Trace | DXC=2\TRUlGQ3;d<^_jE4S2b@oL?0kYOcDh@jW\:Hm@YlDbj<TI19YRKJQdUGD@iN[Hd?oH:7hce7QGOi |
| Xref | x330-a1.tempe.blueboxinc.net comp.lang.python:5391 |
Show key headers only | View raw
TheSaint <nobody@nowhere.net.no> writes:
> The example was to show that after having made a set
>
> set(aa)
>
> the need to get that set converted into a list.
As pointed out: you already know how to create a set from an object;
creating a list from an object is very similar:
list(set(aa))
But why are you doing that? What are you trying to achieve?
--
\ “We are all agreed that your theory is crazy. The question that |
`\ divides us is whether it is crazy enough to have a chance of |
_o__) being correct.” —Niels Bohr (to Wolfgang Pauli), 1958 |
Ben Finney
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Converting a set into list TheSaint <nobody@nowhere.net.no> - 2011-05-14 17:02 +0800
Re: Converting a set into list Peter Otten <__peter__@web.de> - 2011-05-14 11:33 +0200
Re: Converting a set into list TheSaint <nobody@nowhere.net.no> - 2011-05-14 22:14 +0800
Re: Converting a set into list Chris Angelico <rosuav@gmail.com> - 2011-05-15 04:22 +1000
Re: Converting a set into list Ben Finney <ben+python@benfinney.id.au> - 2011-05-15 00:12 +1000
Re: Converting a set into list TheSaint <nobody@nowhere.net.no> - 2011-05-14 22:51 +0800
Re: Converting a set into list Ben Finney <ben+python@benfinney.id.au> - 2011-05-15 09:21 +1000
Re: Converting a set into list Chris Torek <nospam@torek.net> - 2011-05-15 02:11 +0000
Re: Converting a set into list SigmundV <sigmundv@gmail.com> - 2011-05-15 04:18 -0700
Re: Converting a set into list SigmundV <sigmundv@gmail.com> - 2011-05-15 04:23 -0700
Re: Converting a set into list TheSaint <nobody@nowhere.net.no> - 2011-05-15 23:56 +0800
Re: Converting a set into list Thomas Rachel <nutznetz-0c1b6768-bfa9-48d5-a470-7603bd3aa915@spamschutz.glglgl.de> - 2011-05-15 22:27 +0200
Re: Converting a set into list Daniel Kluev <dan.kluev@gmail.com> - 2011-05-16 13:37 +1100
Re: Converting a set into list Peter Otten <__peter__@web.de> - 2011-05-16 08:34 +0200
Re: Converting a set into list TheSaint <nobody@nowhere.net.no> - 2011-05-16 22:23 +0800
Re: Converting a set into list Ben Finney <ben+python@benfinney.id.au> - 2011-05-17 10:33 +1000
Re: Converting a set into list Roy Smith <roy@panix.com> - 2011-05-15 13:07 -0400
Re: Converting a set into list TheSaint <nobody@nowhere.net.no> - 2011-05-16 00:05 +0800
Re: Converting a set into list Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2011-05-15 16:28 +0000
Re: Converting a set into list TheSaint <nobody@nowhere.net.no> - 2011-05-16 00:35 +0800
Re: Converting a set into list Duncan Booth <duncan.booth@invalid.invalid> - 2011-05-16 10:24 +0000
Re: Converting a set into list Chris Torek <nospam@torek.net> - 2011-05-17 01:07 +0000
csiph-web