Add count bit function.