using System;
public class Program
{
public static void Main()
{
int Input = int.Parse(Console.ReadLine());
int Wind = 2;
int Que = 0;
if (Input==0)
{
Console.WriteLine(0);
}
else
{
while ((Input / Wind )> 0 || Input % Wind == 1)
{
if (Input % Wind == 1)
{
Que++;
}
Input /= Wind;
}
Console.WriteLine(Que);
}
}
}

京公网安备 11010502036488号