5 Feb
2009
5 Feb
'09
5:05 a.m.
I forgot one other comment... Riobard Zhan wrote:
- I noticed a strong tendency to forget colons by new users of Python in a second-year computer science undergraduate course. The students seemed not getting used to colons even near the end of the course.
While I would not support the removal of colons, I would support a better error message when one is missing.
for x in 1,2,3 File "<stdin>", line 1 for x in 1,2,3 ^ SyntaxError: invalid syntax
Perhaps this should say why the syntax is missing? SyntaxError: linebreak in statement or missing colon -- Steven