Commit 5b58e30d by BellCodeEditor

save project

parent d4b12436
Showing with 41 additions and 0 deletions
import random
list["石头",""]
\ No newline at end of file
player=input("请出拳(石头/剪刀/布):")
print(player)
import random
list=["石头","剪刀","布"]
letter=random.choice(list)
print(letter)
if player == "石头":
if letter == "布":
print("你输了")
if player == "石头":
if letter == "石头":
print("平局")
if player == "石头":
if letter == "剪刀":
print("你赢了")
if player == "剪刀":
if letter == "布":
print("你赢了")
if player == "剪刀":
if letter == "石头":
print("你输了")
if player == "剪刀":
if letter == "剪刀":
print("平局")
if player == "布":
if letter == "布":
print("平局")
if player == "布":
if letter == "石头":
print("你赢了")
if player == "布":
if letter == "布":
print("平局")
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