On 02/11/14 21:49, Dave Angel wrote:
But it doesn't. print() returns None, which is false.
Oops, of course it does! I got confused by looking in the interpreter which, of course, printed out the string but I mistook it for a return value! So in fact Clayton's code never executes the exec() at all because an initial false in an and terminates evaluation. -- Alan G Author of the Learn to Program web site http://www.alan-g.me.uk/ http://www.flickr.com/photos/alangauldphotos _______________________________________________ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: https://mail.python.org/mailman/listinfo/tutor