> On Feb 7, 2017, at 15:09, တာန္ခတ္သန္ <pkhat...@gmail.com> wrote:
> 
> 
> # RockPaperScissors
> 
> import random
> print ("Hello.. Welcome from Rock, Paper, Scissors Game!!\n"
>       +"Game instruction:\n"
>       +"You will be playing with the computer.\n"
>       +"You need to choose one of your choice: Rock, Paper or Scissors.\n"
>       +"Enter 'e' to exit the game.\n")
> 
> game_command = {"r":"Rock","p":"Paper","s":"Scissors","e":"Exit"}
> 
> 
> score = 0
> player = 0
> try:
>    while player == 'r' and player == 'p' and player == 's':
> 

There are two major things that you need to address first.

1. You never ask for user input before starting your while loop
2. Your while loop is testing for r, p, and s to all be equal to each other and 
set, which is not what you want to test.

Basically, your while loop is immediately false as soon as you run your script. 
 You need to rework your logic to test the player’s value.


— 
David Rock
da...@graniteweb.com




_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor

Reply via email to