Commit 8d48fcc4 by BellCodeEditor

save project

parent aaddf24b
Showing with 8 additions and 6 deletions
import random
sb2=input("出拳吧!爸爸:")
list1=["剪刀","石头","布"]
computer=random.choice(list1)
print(sb2)
if sb2 in list1:
while True:
sb2=input("出拳吧!爸爸:")
list1=["剪刀","石头","布"]
computer=random.choice(list1)
print(sb2)
if sb2 in list1:
if sb2 == computer:
print("平局")
elif(sb2=="石头" and computer=="剪刀")or(sb2=="剪刀" and computer=="布")or(sb2=="布" and computer=="石头"):
print("wc,爸爸赢啦")
else:
print("爸爸输啦")
else:
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