User inputted integer using while statement
<p>Ok need to understand why my code is not working.
At the moment it's getting stuck in a infinite loop of asking the user for a pin after a wrong pin is inputted.</p>

<p>I believe I'm screwing up the while statement somehow.</p>

<pre><code>def inputValidator():
    userInput = requestInteger("Please input a PIN between 1 - 1000")
    while 1 &gt; userInput &gt; 1000 : 
        requestInteger("Your PIN is not within 1 - 1000, please try again")
    print("Thanks! your new PIN is " + str(userInput))
</code></pre>

<p>thanks for the help guys!</p>

<p>you aren't assigning requestInteger to userInput </p>

<pre><code>while 1 &gt; userInput &gt; 1000 : 
  userInput =requestInteger("Your PIN is not within 1 - 1000, please try again")
</code></pre>

python