title: double equals vs is in python
body: <p>I run the following in the Python interpreter:</p>
  
  <pre class="lang-python prettyprint-override"><code>&gt;&gt;&gt; foo = 10
  &gt;&gt;&gt; dir(foo) == dir(10)
  True
  &gt;&gt;&gt; dir(foo) is dir(10)
  False
  &gt;&gt;&gt; 
  </code></pre>
  
  <p>Why is this?</p>