Commit 626c9e40 by BellCodeEditor

save project

parent cf9b9614
Showing with 10 additions and 2 deletions
import random import random
player=input("请输入你想出的手势")
print("玩家出的是"+player)
list=["石头","剪刀","布"] list=["石头","剪刀","布"]
com=random.choice(list) com=random.choice(list)
print("电脑出的是"+com) print("电脑出的是"+com)
\ No newline at end of file if player==com:
print("平局")
elif (player=="剪刀"and com=="布")or(player=="布"and=="石头")or(player=="石头"and com=="剪刀":
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