Python SyntaxError: Missing parentheses in call to 'print'

mac2022-06-30  99

下面的代码

print "hello world"

会出现下面的错误

SyntaxError: Missing parentheses in call to 'print'

因为写的代码和系统中的python不是一个版本的。 python2系列可以支持

print "hello world"

python3系列的需要使用

print("hello world")

转载于:https://www.cnblogs.com/vercont/p/10210227.html

相关资源:JAVA上百实例源码以及开源项目
最新回复(0)