我目前正在学习 Python The Hard Way。我认为这个例子可能已经过时了,所以我想在这里得到反馈。
我正在使用 Python 3.1
from sys import argv
script, first, second, third = argv
print("the script is called:", (script))
print("your first variable is:", (first))
print("your second variable is:", (second))
print("your third variable is:", (third))
我收到此错误:
Traceback (most recent call last):
File "/path/ch13.py", line 3, in <module>
script, first, second, third, bacon = argv
ValueError: need more than 1 value to unpack
知道有什么问题吗?