#include using namespace std; int count(long n) { int num = 0; if (n) do num++; while (n &= n - 1); return num; } int main() { int n; cin>>n; cout<