[Tutor] Program Questions (original) (raw)
Alan Gauld alan.gauld at blueyonder.co.uk
Tue Jul 20 00:03:29 CEST 2004
- Previous message: [Tutor] Program Questions
- Next message: [Tutor] Program Questions
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
In my mail tool they were the only bits that had any indentation at all! It would be useful if you can find a way to send plain text since Python indentation is critical, not to mention easier to read!
BTW Instead of
print '\n' print 'foo' print '\n'
its easier to do:
print '\nfoo\n'
or even
print ''' foo
'''
personally I'd go for the first option.
Where you need to substitute a function call use a format string:
print "\n%s\n" % acct.foo()
It keeps it shorter and easier to read.
As to the error, again it helps if you post the actual error report.
Alan G Author of the Learn to Program web tutor http://www.freenetpages.co.uk/hp/alan.gauld
- Previous message: [Tutor] Program Questions
- Next message: [Tutor] Program Questions
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]