[Tutor] print 'hello world' - invalid syntax
alan.gauld at btinternet.com
Sun May 20 20:48:44 CEST 2012
On 20/05/12 19:08, Quidam S-enfuit wrote:
> I have installed python on the windows 7 machine. (Tried 64 bit version
> also; same error).
> I tried print "Hello world" and print 'hello world'. It stated syntax
As others have said you are using version 2 syntax with version 3 Python.
You need to "downgrade" to version 2.7 of Python or find a version 3
If you have programmed before in another language you should probably
stick with v3 and use the official tutorial on the Python web site.
If you are a complete beginner to programming and Python then you need
to visit the beginners page and find a v3 tutor you like (you could try
Or downgrade to 2.7 and use any of the many v2 tutorials out there
(including mine! :-)
Author of the Learn to Program web site
More information about the Tutor