Untitled

 avatar
unknown
python
a year ago
1.3 kB
10
Indexable
from random import randint

print("Hello and welcome to 'Rock, paper and scissor'! Let's play by choose what you will use to fight against me (Rock/Paper/Scissor)" )

a = input()
b = randint(1,3)

print("You chooose:", a)
if (b == 1) :
    print("Computer choose: Rock")
elif (b == 2) :
    print("Computer choose: Paper")
elif (b == 3) :
    print("Computer choose: Scissor")
if (a == "Rock"):
    if (b == 1):
        print("It's a draw for you.")
    elif (b == 2):
        print("It's a lose for you. Better good luck next time, loser, haha.")
    elif (b == 3):
        print("It's a win for you. You just luckier than me this time. Congratulation!")
elif (a == "Paper"):
    if (b == 1):
        print("It's a win for you. You just luckier than me this time. Congratulation!")
    elif (b == 2):
        print("It's a draw for you.")
    elif (b == 3):
        print("It's a lose for you. Better good luck next time, loser, haha.")
elif (a == "Scissor"):
    if (b == 1):
        print("It's a lose for you. Better good luck next time, loser, haha.")
    elif (b == 2):
        print("It's a win for you. You just luckier than me this time. Congratulation!")
    elif (b == 3):
        print("It's a draw for you.")
Editor is loading...
Leave a Comment