Commit 8419e175 by BellCodeEditor

save project

parent dcb4d051
Showing with 4 additions and 3 deletions
...@@ -6,11 +6,11 @@ cp=random.choice(list) ...@@ -6,11 +6,11 @@ cp=random.choice(list)
print(cp) print(cp)
if player == cp: if player == cp:
print("平局!") print("平局!")
elif player=="布" and cp=="石头" elif player=="布" and cp=="石头":
print("玩家赢!") print("玩家赢!")
elif player=="石头" and cp=="剪刀" elif player=="石头" and cp=="剪刀":
print("玩家赢!") print("玩家赢!")
elif player=="剪刀" and cp=="布" elif player=="剪刀" and cp=="布":
print("玩家赢!") print("玩家赢!")
else: else:
print("电脑赢!") 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