Commit 1c2838f8 by BellCodeEditor

auto save

parent 82852967
Showing with 9 additions and 2 deletions
...@@ -3,4 +3,12 @@ print("玩家出拳:"+player) ...@@ -3,4 +3,12 @@ print("玩家出拳:"+player)
import random import random
list=["石头","剪刀","布"] list=["石头","剪刀","布"]
comupter=random.choice(list) comupter=random.choice(list)
print(comupter) print(comupter)
\ No newline at end of file if player==comupter:
print("平局")
elif (player=="布" and comupter=="石头") or (player=="石头" and comupter=="布") or (player=="剪刀" and comupter=="布")
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