Commit cf6bb0fa by BellCodeEditor

save project

parent cf20d3b2
Showing with 10 additions and 4 deletions
cost={'苹果':5.2'山竹'12.9'香蕉'3.8}
cost={'苹果':5.2,'山竹':12.9,'香蕉':3.8}
k=input('输入水果名称:')
v=input('输入水果价钱:')
if k in co
if k in cost:
if float(v)<cost[k]:
cost[k]=float(v)
print(k+'降价了,现价'+str(v)+'元')
else:
print('涨价')
elif:
print('降价了')
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment