#include int main() { int N; scanf ("%d", &N); int i, c=0; for (i=31; i>=0; --i) c += (N >> i) & 1; printf ("%d\n", c); return 0; }