title: Why does Python's hash of infinity have the digits of π?
body: <p>The hash of infinity in Python has digits matching <a href="https://en.wikipedia.org/wiki/Pi" rel="noreferrer">pi</a>:</p>
  
  <pre><code>&gt;&gt;&gt; inf = float('inf')
  &gt;&gt;&gt; hash(inf)
  314159
  &gt;&gt;&gt; int(math.pi*1e5)
  314159
  </code></pre>
  
  <p>Is that just a coincidence or is it intentional?</p>