下面代码的执行结果是 desserts=[’ice cream’,’chocolate’,’apple crisp’,’cookies’] favorite_dessert=’apple crisp’ for dessert in desserts: if

admin2019-09-02  28

问题 下面代码的执行结果是
desserts=[’ice cream’,’chocolate’,’apple crisp’,’cookies’]
favorite_dessert=’apple crisp’
for dessert in desserts:
if dessert==favorite_dessert:
print(’’%s is my favorite dessert!”%dessert.title())

选项 A、chocolate is my favorite dessert!
B、ice cream is my favorite dessert!
C、apple Crisp is my favorite dessert!
D、Apple Crisp is my favorite dessert!

答案D

解析
转载请注明原文地址:https://kaotiyun.com/show/336p777K
0

相关试题推荐
随机试题
最新回复(0)