title: NaN for an unknown reason
body: <p>While coding a little project I came across a NaN issue when printing to the console.  I thought this would be easily remedied by using the JavaScript code:</p>
  
  <pre><code>newInt = parseInt(oldInt);
  </code></pre>
  
  <p>This was not to be the case.  After reading up on NaN, it can be created in a number of ways, such as adding an array to an object, or more commonly when you try to take away a number from a string.  I say take away because adding a number to a string means that concatenation will occur.</p>
  
  <p>My code is available <a href="http://jsfiddle.net/8okcwL53/" rel="nofollow">here</a>.  It is all one website, however I use appearing and disappearing divs to appear that it's not.  To get the error, press "Start the Adventure".  You can use default values.</p>
  
  <p>In console, which you can access by pressing <kbd>F12</kbd>, it will print off a set of starting values.  Then it will print a set of starting values, conveniently grouped together using:</p>
  
  <pre><code>console.Group();
  console.GroupEnd();
  </code></pre>
  
  <p>After that, when you press "Next Year!" it will print two more groups.  The first one created by the function </p>
  
  <pre><code>plantCrops();
  </code></pre>
  
  <p>The next one created by the function</p>
  
  <pre><code>buildWells(); 
  </code></pre>
  
  <p>As you can see, both currentCrop comments are NaN - despite taking precauations by using parseInt a lot.  Is there any way to fix this?  It seems strange that it's happening despite the fact that it should be very simple.</p>