a.py
386 Bytes
# list_xx=['x',3,'xx',20,'xxx',42]
# dict_xx = {'x':3,'xx':20,'xxx':42}
# list_xx[3]=40
# print(list_xx)
# dict_xx['xx']=40
# print(dict_xx)
# list=[]
# dict={}
# dict['x']='xx'
# print(dict['x']='xx')
x={'x':1,'xx':2,'xxx':3}
k=input('你要什么')
if k in x:
print('叮~你的'+k+'需要支付'+str(x[k])+'元~')
else:
print('没有你要的东西,滚!')