Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
philipbjorge
on March 16, 2013
|
parent
|
context
|
favorite
| on:
Adding Empty Set Literals to Python
I originally implemented it that way and had that exact same issue (it's one of the revisions on github). Similarly, {/} would also be a problem.
digisign
on March 16, 2013
[–]
How about {,} or s{} ?
mkhattab
on March 16, 2013
|
parent
|
next
[–]
I think {,} is intuitive because it reminds me of syntax for one-element tuples, e.g. (1,) -- but it may make code harder to read, which is not Pythonic.
philipbjorge
on March 16, 2013
|
parent
|
prev
[–]
I didn't think to do {,} which I like. s{} looks weird to me, but I couldn't tell you why.
digisign
on March 16, 2013
|
root
|
parent
[–]
The s{} alternatve is based on the strange r'' or u'' syntax i've gotten used to.
Join us for
AI Startup School
this June 16-17 in San Francisco!
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: