Commit 59b1a3e7 by BellCodeEditor

save project

parent cd5cb9df
Showing with 1 additions and 13 deletions
fruit = {'apple':5,'banana':3}
while True:
k = input("你要啥水果")
v = input("今天的水果价格")
if k in fruit:
print(fruit[k])
if int(v) > fruit[k]:
print("涨价了")
else:
print("减价了")
else:
fruit[k]=v
print(fruit)
\ 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