Java Finding Set Bits of Long
<p>I have a long number. Now what I want is following (given in pseudo code) ,</p>

<pre><code>for each two bits of that long

if the two bits == 11

then count++

(for example if number is "11 01 10 00 11" it will give count = 2)
</code></pre>

<p>Can anybody help me how to do this efficiently in Java ?</p>
