title: Two Player Number Guessing Game - Python
body: <p>I am trying to write a game where Player One picks a number and Player Two has 5 Guesses to guess it. If he manages to do so, he wins, if not, he losses and Player One wins.</p>
  
  <p>So I have the code, but if for example Player one picks the number '3' and Player Two enters the number '3' on any of his goes, it still says Player One wins. </p>
  
  <pre><code>&gt;&gt;&gt; 
  Player One enter you chosen number: 3
  Player Two have a guess: 3
  Player One wins.
  &gt;&gt;&gt; 
  </code></pre>
  
  <p>This happens also: </p>
  
  <pre><code>&gt;&gt;&gt; 
  Player One enter you chosen number: 5
  Player Two wins.
  </code></pre>
  
  <p>Also, player two can have as many turns as he likes, but it should only be 5. If he passes that amount, Player One automatically wins. Here is my code: (I don't know here I went wrong.)</p>
  
  <pre><code>def Game():
      Guess = 0
      NumberOfGuesses = 0
      NumberToGuess = int(input("Player One enter you chosen number: "))
      while NumberToGuess &lt; 1 or NumberToGuess &gt; 10:
          NumberToGuess = int(input("Not a valid choice, please enter another number: "))
      while Guess != NumberToGuess and NumberOfGuesses &lt; 5:
          Guess = int(input("Player Two have a guess: "))
          NumberOfGuesses = NumberOfGuesses + 1
      if Guess == NumberToGuess:
          print("Player One wins.")
      else:
          print("Player Two wins.")
  
  
  Game()
  </code></pre>