[Python-3000] sets in P3K?

Neal Norwitz nnorwitz at gmail.com
Wed May 3 07:41:03 CEST 2006


On 5/2/06, Raymond Hettinger <rhettinger at ewtllc.com> wrote:
>
> I think Guido had the best solution.  Use set() for empty sets, use {}
> for empty dicts, use {genexp} for set comprehensions/displays, use
> {1,2,3} for explicit set literals, and use {k1:v1, k2:v2} for dict
> literals.  We can always add {/} later if demand exceeds distaste.

Presumably {1, 2, 3: 4} would yield a syntax error?

n


More information about the Python-3000 mailing list