difference between var keyword and without var
<blockquote>
  <p><strong>Possible Duplicate:</strong><br>
  <a href="http://stackoverflow.com/questions/1470488/difference-between-using-var-and-not-using-var-in-javascript">Difference between using var and not using var in JavaScript</a>  </p>
</blockquote>



<p>What is the difference between using var keyword in java script &amp; without using it for a variable?</p>

<p>For example:</p>

<pre><code>var x = 14;
</code></pre>

<p>And <code>x = 14;</code></p>

<p>Are these same or when we declare var x, its a local variable &amp; when it doesn't have var keyword, then its global?</p>

<p>Thanks!</p>
