String concatenation
Leif B. Kristensen
junkmail at solumslekt.org
Fri Apr 2 04:00:49 EST 2004
Erik Max Francis wrote:
> Probably you included the initial spaces, which is a no-no:
No I didn't. The text is properly aligned. The relevant code now looks
exactly like this:
res=c.fetchone()
tmp=[x for x in res if x and x[0] != '-']
return ', '.join(tmp)
And here's what the interpreter says:
tmp=[x for x in res if x and x[0] != '-']
^
SyntaxError: invalid syntax
The marker has moved to the right, maybe because I removed the spaces on
both sides of the = sign?
regards,
--
Leif Biberg Kristensen
http://solumslekt.org/
Validare necesse est
More information about the Python-list
mailing list