Commit 0377e802 by BellCodeEditor

save project

parent b5c6bbbe
Showing with 15 additions and 0 deletions
a=input("请出拳:")
print("玩家出拳:"+a)
import random
b=["布","剪刀","石头"]
f=random.choice(b)
print("计算机出拳:"+f)
if a in b:
if a==f:
print("平局")
elif(a=="石头" and f=="剪刀")or(a=="布" and f=="石头")or(a=="剪刀" and f=="布"):
print("玩家赢")
else:
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