n = int(input())
n = bin(n)
print(n.count('1'))