MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/Python/comments/5eljwc/the_case_for_python_3/daejw26
r/Python • u/earthboundkid • Nov 24 '16
349 comments sorted by
View all comments
Show parent comments
1
I have to make a dictionary that I don't have rather than doing something like 'x={x} y={y}' % (y, x)` where the code is smart enough to see that I wrote the variables backwards.
'x={1}, y={0}'.format(1, 2).
'x={1}, y={0}'.format(1, 2)
1 u/billsil Nov 26 '16 That kind of defeats the purpose...how is that better than 'x=%s y=%s' % (2, 1)
That kind of defeats the purpose...how is that better than 'x=%s y=%s' % (2, 1)
'x=%s y=%s' % (2, 1)
1
u/zahlman the heretic Nov 25 '16
'x={1}, y={0}'.format(1, 2).