如何在此代码中添加“int”,以便三者中至少有一个必须是整数?
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
答案 0 :(得分:1)
你没有。你是分开做的。
second = int(second)