title: bit count function in K&R
body: <p>In the book "C Programming Language" by K&amp;R, there is a bit count function:</p>
  
  <pre><code>int bitsCount(unsigned x)
  {
      int b;
      for (b = 0; x != 0; x &gt;&gt;= 1)
          if (x &amp; 01)
              b++;
      return b;
  }
  </code></pre>
  
  <p>My question is why they use <strong>x &amp; 01</strong> but not <strong>x &amp; 1</strong> or <strong>x &amp; 00000001</strong>? Isn't that 01 means octal 1?</p>