Name: Anonymuus 2011-05-15 2:50
Working on python code, there are a few ways to contract code:
can be written as:
something like
is perfectly like acceptable in one line, yet these don't work for one reason or another:
because nesting a loop or a condition anywhere but the beginning of a line gives a syntax error.
Is is possible any other way?
print 'hi'
print 'ho'can be written as:
print 'hi';print 'ho'something like
for i in range(9):print iis perfectly like acceptable in one line, yet these don't work for one reason or another:
print 'hi';for i in range(9):print ifor i in range(9):if i != 8:print iif i != 8: print i;else:print 'no'because nesting a loop or a condition anywhere but the beginning of a line gives a syntax error.
Is is possible any other way?