Commit ffbb38ae by BellCodeEditor

save project

parent 44a9f69d
Showing with 2001 additions and 4 deletions
import random
SB=input("玩家请出拳")
print("玩家出了"+SB)
pp=["石头","剪刀","布"]
a=random.choice(pp)
print("机器人出了什么"+a)
if SB==a:
if SB in pp:
if SB==a:
print("平局")
elif SB=="剪刀"and a=="布" or SB=="石头" and a=="剪刀" or SB=='布'and a=="剪刀":
elif SB=="剪刀"and a=="布" or SB=="石头" and a=="剪刀" or SB=='布'and a=="剪刀":
print("玩家你赢了")
else:
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