#include int main() { int N, ans = 0; scanf("%d", &N); while (N > 0) { ans += (N & 1); N >>= 1; } printf("%d\n", ans); return 0; }