Counts the number of set bits in an integer by repeatedly stripping away the rightmost set bit.
Explain code with DocComment! Try out your own code!