title: Why isn't the conditional message displaying and instead it executes the rest?
body: <p>I am receiving the users input and I want it to validate whether the number is valid. If it is not between 0-100, then I want to show the message 'Not Valid'. Right now even if I enter 2000 it will still display if the user is warm or cold. I want it to stop executing and display the invalid message.</p>
  <pre><code>// Hot or Cold JS game.
  $(document).ready(function() {
      $('#number').on('keyup keypress', function(e) {
          if (e.keyCode &lt; 48 || e.keyCode &gt; 57)
              return false;
      });
      var randomNumber = Math.floor((Math.random() * 100 ) + 1);
  
      $('#Enter').click(function() {
          var guessNumber = document.getElementById('number').value;
          if (guessNumber &lt; 0 || guessNumber &gt; 100) {
              // Display invalid input
              console.log('Not valid');
              $('output-container').text('Enter a number between 0 and 100').css('color', 'silver');
          };
          var difference = Math.abs(guessNumber - randomNumber);
  
          if (difference == 0) {
              // Display to user - &quot;Perfect&quot;
              $('.output-container').text('Perfect').css('color', 'green');
          } else if (difference &lt; 5) {
              // Display to user - You're on Fire!
              $('.output-container').text('You are on Fire!').css('color', 'red');
          } else if (difference &lt; 10) {
              // Display to user - Warm
              $('.output-container').text('Warm').css('color', 'orange');
          } else if (difference &lt; 30) {
              // Display to user - Ice Cold
              $('.output-container').text('Ice Cold').css('color', 'blue');
          } else {
              // Display to user - You must be Frozen?
              $('.output-container').text('You must be Frozen!').css('color', 'royalblue');
          };
      });
  
      // Start over
      $('#reset').click(function() {
          location.reload();
      });
      $('#show').click(function() {
          $('#show').hide();
          $('#append-number').append(randomNumber);
      });
  });
  </code></pre>
  <p>Here is a sample of how it is running. <a href="http://jsfiddle.net/jonathanbello/32cuW/" rel="nofollow noreferrer">http://jsfiddle.net/jonathanbello/32cuW/</a></p>