[Tutor] "Print" on 3.1 for Mac?

Christian Witts cwitts at compuscan.co.za
Mon Jun 29 12:59:30 CEST 2009


lev at ithstech.com wrote:
> Have I installed something incorrectly in Python 3.1 for Mac if I get a
> syntax error on
>
> print "hello world"
>
> ?
>
> My Python 2.3.5 executes this just fine.  What have I missed?
>
> Thanks much for anything, Lev
>
>
>
> _______________________________________________
> Tutor maillist  -  Tutor at python.org
> http://mail.python.org/mailman/listinfo/tutor
>
>   
Please take a read through http://docs.python.org/3.0/whatsnew/3.0.html 
for a list of changes from the 2.x series to 3.x.  It includes the fact 
that the print command is now a function and needs to be called 
accordingly, ie. print("Hello world!")

-- 
Kind Regards,
Christian Witts




More information about the Tutor mailing list