Commit af2adc6e by BellCodeEditor

auto save

parent fa0dff60
Showing with 16 additions and 0 deletions
import random
list = ["石头","剪刀","布"]
me = input("请你输入")
computer = random.choice(list)
if me in list:
if (computer == "石头" and me == "剪刀") or (computer == "剪刀" and me == "布") or (computer == "布" and me == "石头"):
print("电脑赢")
elif computer == me:
print("平局")
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