On 21/02/12 03:07, Michael Lewis wrote:
Now that I am better understanding '__name__'=='__main__',
> if '__name__' == '__main__':
> GetUserInput()
Note that __name__ is a variable so it should NOT have quotes around it.
What you are doing is comparing two literal strings which are obviously
different so the if block never gets executed.
It has to be:
if __name__ == '__main__':
GetUserInput()
HTH
--
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/
_______________________________________________
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor