Commit 10505589 by BellCodeEditor

save project

parent f1275238
Showing with 7 additions and 0 deletions
......@@ -6,3 +6,9 @@ import random
list = ["石头","剪刀","布"]
n=random.choice(list)
print("玩家2 出拳:" + n)
if s == n:
print("平局")
elif (s == "石头" and n == "剪刀") or (s == "剪刀" and n == "布") or (s == "布" and n == "石头"):
print("恭喜,你赢了!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!")
else:
print("很遗憾,你输了!!!!!!!!!")
\ No newline at end of file
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