Hi guys, in this video I'm going to show you how to make a Rock, Paper and Scissors Game using python. so if you like this video, please Subscribe to my channel for more programming-like content.
#python
Code:-
#RockPaperScissors
import random
def play():
user = input("What is Your Choice. Rock , Paper or Scissors?: ")
computer = random.choice(['Rock', 'paper', 'Scissors'])
if user == computer:
return ("It's a Tie :/")
if is_win(user, computer):
return "You Won ! :)"
return "You Lost :("
def is_win(player, opponent):
if (player == "Rock" and opponent == "Scissors") or (player == "Scissors" and opponent == "paper") \
or (player == "paper" and opponent == "Rock"):
return True
print(play())
Thank You For Watching :)
Nesta página do site você pode assistir ao vídeo on-line How To Make a Rock, Paper and Scissors Game | Using Python | Beginners Python Project | duração hora minuto segundo em boa qualidade , que foi baixado pelo usuário ProrammingWith Somesh 15 Junho 2021, compartilhe o link com seus amigos e conhecidos, no youtube este vídeo já foi visto 35 vezes e gostou 7 espectadores. Boa visualização!