x## python编程从入门到实践练习7-10:梦想的旅游胜地
#调查用户梦想的旅游胜地显然要用户有旅游胜地一一相对应,
#创建一个空字典
resorts = {}
#设置一个标志指出调查是否继续
active = True
while active:
#提示输入用户名和旅游胜地名称
name = input('nWhat`s your name?')
resort = input('nIf you could visit one place in the
world, where would you go?')
#将人名和旅游胜地添加进字典中
resorts[name] = resort
#询问是否还有人参与调查
repeat = input(f'nWould you like let another resorts(yes/no)?')
if repeat == 'no':
active = False
#调查结束,显示结果
print('---Poll Resules--- ')
for name,resort in resorts.items():
print(f'n{name} would like to {resort}.')



