PEP-xxx: Unification of for statement and list-comp syntax

Edward Elliott nobody at
Mon May 22 18:58:41 CEST 2006

bruno at modulix wrote:

> Edward Elliott wrote:
>> You mean like this:
>> s = "foo" + "bar"
>> s = 'foo' + 'bar'
>> s = 'foo' 'bar'
>> s = '%s%s' % ('foo', 'bar')
> The real mantra is actually :
> "There should be one-- and preferably only one --obvious way to do it"
> Please note the "should", "preferably", and "obvious".

Touche.  Please tell me which of the above should obviously be the
preferable way to concatenate strings.  All those weasel words prove my
point: it's a vague and watered-down guideline that gives way in the face
of other considerations.

Edward Elliott
UC Berkeley School of Law (Boalt Hall)
complangpython at eddeye dot net

More information about the Python-list mailing list