Why are Integer.parseInt(String s, 2) and Integer.toBinaryString(int i) incompatible?
<p>Why are this two methods using two different approaches while processing binary numbers? String which represents negative binary number in <code>Integer.parseInt(String s, 2)</code> method should start with <code>-</code> character, but <code>Integer.toBinaryString(int i)</code> returns string with additional 1 ahead. So, this code</p>

<pre><code>Integer.parseInt(Integer.toBinaryString(-1), 2);
</code></pre>

<p>throws <code>java.lang.NumberFormatException</code>. What is the reason of such behavior? </p>
