我正在尝试使用命令提示符在 python 3.6 上安装模式:
pip3 install pattern
但是我收到了这个错误:
C:\WINDOWS\system32>pip3 install pattern
Collecting pattern
Using cached pattern-2.6.zip
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Users\HP\AppData\Local\Temp\pip-build-u_5lhmfa\pattern\setup.py", line 40
print n
^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(int n)?
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in C:\Users\HP\AppData\Local\Temp\pip-build-u_5lhmfa\pattern\
顺便说一句,我也安装了 Python 2.7,当我安装时pip2 install pattern
,它完美安装。
问题出在python 3.6上。我怎样才能解决这个问题?