a = int(input())
b = bin(a)
print(b.count('1'))