Commit 270d5f55 by BellCodeEditor

save project

parent 2cfa14b2
Showing with 13 additions and 4 deletions
player=input("石头,剪刀") player=input("石头|剪刀|布")
print("+player") print("+player")
import random import random
list=[""] list=["石头|剪刀|布"]
comput=random.choice(list) computer=random.choice(list)
\ No newline at end of file print("电脑出拳:"+computer)
if player==computer:
print("平")
elifplayer=="石头"and computer=="剪刀")or
(player=="剪刀"and computer=="布")or)
(player=="布"and computer=="石头")
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