#include <stdio.h> int main() { int n; scanf("%d", &n); int res = 0; while (n) { res += n & 1; n >>= 1; } printf("%d", res); return 0; }