count occurences of "1" bit