On 12/29/2009 5:51 AM Victor Subervi said...
> # print 'XXX', types[x] > elif types[x][0:3] == 'set': > for f in field: > print '<td>AAA%s</td>\n' % (field) > else: > print 'YYY' > > 1) If I uncomment the commented line, it throws this error: > What happens if you *don't* uncomment the commented line?As I mentioned, it prints BOTH the AAA and the YYY lines! The AAA is printed with something like this: AAASet([purple:223344])
Yes -- that's what a for-else does. See http://www.ibiblio.org/swaroopch/byteofpython/read/for-loop.html for example.
Emile -- http://mail.python.org/mailman/listinfo/python-list
