From 2000f937e4afb2328e082c36654605875e6378a8 Mon Sep 17 00:00:00 2001 From: BellCodeEditor <bellcode_dev@bell.ai> Date: Sat, 19 Dec 2020 14:58:28 +0800 Subject: [PATCH] save project --- star.py | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/star.py b/star.py index 6685465..f2c1409 100644 --- a/star.py +++ b/star.py @@ -1,7 +1,16 @@ - inport random -print(input("玩家请出拳")) +player == print(input("玩家请出拳")) print == ("玩家出:" + name) lest=["石头","剪刀","布"] computer==random.choice(list) -print("计算机请出拳:",computer) \ No newline at end of file +print("计算机请出拳:",computer) +if player == computer: + print(平局!) +elif player("石头") == computer("剪刀"): + print(恭喜,你赢了!) +elif player("剪刀") == computer("布"): + print(恭喜,你赢了!) +elif player("布") == computer("石头"): + print(恭喜,你赢了!) +else: + print(SB,你死了!) \ No newline at end of file -- libgit2 0.25.0