Commit e0279d93 by BellCodeEditor

save project

parent d2109113
Showing with 17 additions and 13 deletions
player=input("请出拳(石头/剪刀/布):") while True
print("玩家出拳:"+player) player=input("请出拳(石头/剪刀/布):")
import random print("玩家出拳:"+player)
list1 = ["剪刀","石头","布"] import random
cmp = random.choice(list1) list1 = ["剪刀","石头","布"]
print("电脑出拳:"+cmp) cmp = random.choice(list1)
if cmp == player: print("电脑出拳:"+cmp)
print("平局") if player in list1
elif player=="剪刀" and cmp=="布" or player=="石头" and cmp=="剪刀" or player=="布" and cmp=="石头": if cmp == player:
print("你赢了!!!!!!!!!!!") print("平局")
else: elif player=="剪刀" and cmp=="布" or player=="石头" and cmp=="剪刀" or player=="布" and cmp=="石头":
print("你死了!!!") print("你赢了!!!!!!!!!!!")
\ No newline at end of file else:
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