Commit fe24af4f by BellCodeEditor

save project

parent 7d694f9d
Showing with 10 additions and 3 deletions
player=input("请出拳:石头/剪刀/布")# 玩家出拳 p=input("请出拳:石头/剪刀/布")# 玩家出拳
print("玩家出拳:"+player) print("玩家出拳:"+p)
import random import random
m=["石头","剪刀","布"] m=["石头","剪刀","布"]
l=random.choice(m) o=random.choice(m)
print(l) print(l)
if p==o:
print("平局")
elif (p=="石头" and o=="剪刀") or (p=="剪刀" and o=="布") orp=="布" and o=="石头"):
print("恭喜你赢了!")
else:
print("你输了。")
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