Commit badbc777 by BellCodeEditor

save project

parent 07989386
Showing with 9 additions and 5 deletions
......@@ -4,12 +4,16 @@ z=input("请选择(石头,剪刀,布):")
print("玩家出拳:"+z)
q=random.choice(l)
print(q)
if z==q:
print("平局")
elif (z=="石头" and q=="剪刀") or (z=="剪刀" and q=="布") or (z=="布" and q=="石头"):
print("玩家胜利")
if z in l :
if z==q:
print("平局")
elif (z=="石头" and q=="剪刀") or (z=="剪刀" and q=="布") or (z=="布" and q=="石头"):
print("玩家胜利")
else:
print("电脑胜利")
else:
print("电脑胜利")
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