Count the number of 1 bits in an interger

/**
 * CountTheNumberOf1BitsInAnInteger.java
 * 
 * Description: How would you figure out the number of 1 bits in an
integer?
 * 
 * Follow up: If this were a repeated operation, how could you optimize
this?
 * 
 * @author John Qiao <qiaoshun8888@gmail.com> Date: Jan 25, 2014
 */