Why is (18446744073709551615 == -1) true?
<p>When I was working on <code>string::npos</code> I noticed something and I couldn't find any explanation for it on the web. </p>

<pre><code>(string::npos == ULONG_MAX)
</code></pre>

<p>and </p>

<pre><code>(string::npos == -1)
</code></pre>

<p>are true.</p>

<p>So I tried this:</p>

<pre><code>(18446744073709551615 == -1)
</code></pre>

<p>which is also true.</p>

<p>How can it be possible? Is it because of binary conversation?</p>