https://www.acmicpc.net/problem/1094
using System;
class Program
{
static void Main() {
string s=Console.ReadLine();
int n=int.Parse(s);
int sum=64;
int a=64;
int count=1;
if(n==64) Console.Write("1");
else{
for(int i=0;i<7;i++){
if(sum-a/2>n) sum-=a/2;
else if(sum-a/2<n) count++;
a/=2;
}
Console.WriteLine(count);
}
}
}