Commit b2294df3 by BellCodeEditor

save project

parent b39a7928
Showing with 11 additions and 1 deletions
...@@ -5,4 +5,13 @@ import ramdom ...@@ -5,4 +5,13 @@ import ramdom
list=["剪刀","石头","布"] list=["剪刀","石头","布"]
b=ramdom.choice(list) b=ramdom.choice(list)
print("机器出拳"+b) print("机器出拳"+b)
if a in list:
if a==b:
print("平局")
elif (a=="布" and b=="石头") or (a=="石头" and b=="剪刀") or (a=="剪刀" and b=="布"):
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