Commit d87433bd by BellCodeEditor

save project

parent 421c3481
Showing with 13 additions and 6 deletions
......@@ -12,8 +12,15 @@ pen.end_fill()
turtle.done()
'''
import random
s=input("请玩家出拳(石头,剪刀,布):")
print("玩家出拳为"+s)
list11=["石头","剪刀","布"]
cll=random.choice(list11)
print("电脑出拳为"+cll)
\ No newline at end of file
while True:
s=input("请玩家出拳(石头,剪刀,布):")
print("玩家出拳为"+s)
list11=["石头","剪刀","布"]
cll=random.choice(list11)
print("电脑出拳为"+cll)
if s==cll:
print("平局!")
elif (s=="石头"and cll=="剪刀" )or(s=="剪刀"and cll=="布") or (s=="布"and cll=="石头"):
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