      Set o to Zero. 
      Set r to Zero.
      set b to 2.
      
      Perform PopCount until n is equal to 0.
       
       PopCount.
          Divide b into n giving n remainder r,
          Add r to o.
