Commit 70d818c8 by BellCodeEditor

save project

parent 3c5e77ae
Showing with 6 additions and 4 deletions
...@@ -4,11 +4,13 @@ print("玩家出拳:"+bianliang) ...@@ -4,11 +4,13 @@ print("玩家出拳:"+bianliang)
list=["剪刀","石头","布"] list=["剪刀","石头","布"]
jsj=random.choice(list) jsj=random.choice(list)
print("计算机出拳:"+jsj) print("计算机出拳:"+jsj)
if bianliang==jsj: if bianliang in list:
if bianliang==jsj:
print("平局yeeee") print("平局yeeee")
elif (bianliang=="剪刀" and jsj=="布") or (bianliang=="布" and jsj=="石头") or (bianliang=="石头" and jsj=="剪刀"): elif (bianliang=="剪刀" and jsj=="布") or (bianliang=="布" and jsj=="石头") or (bianliang=="石头" and jsj=="剪刀"):
print("你赢了!耶斯莫拉!") print("你赢了!耶斯莫拉!")
else: else:
print("你输了") 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