Commit c5bb5af7 by BellCodeEditor

save project

parent 0450ee4d
Showing with 10 additions and 2 deletions
impurt random import random
play=input("玩家请出拳.石投、剪刀、不") play=input("玩家请出拳.石投、剪刀、不")
print("玩家请出拳"+play) print("玩家请出拳"+play)
list["石投","剪刀","不"] list=["石投","剪刀","不"]
campoter=random.choice(list) campoter=random.choice(list)
print("人机出拳:"+campoter) print("人机出拳:"+campoter)
if play==campoter:
print("平居")
elif (player=="石投"and campoter=="剪刀")or(player=="不"and campoter=="石投")or(player=="不"and campoter=="石投"):
print("你迎了")
else:
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