问题是:
Clunker Motors Inc. is recalling all vehicles in its Extravagant line from model years 1999-2002 as well all vehicles in its Guzzler line from model years 2004-2007. Given variables modelYear and modelName write a statement that assigns True to recalled if the values of modelYear and modelName match the recall details and assigns False otherwise.
守则:
if 1999 <= modelYear <= 2002 and modelName == "Extravangant":
recalled = True
elif 2004 <= modelYear <= 2007 and modelName == "Guzzler":
recalled = True
else:
recalled = False
无法在检查其他人的代码后找出缺少的内容
Extravangant
拼写错误。它应该是Extravagant
。也许这就是问题所在相关问题 更多 >
编程相关推荐