#include using namespace std; int main() { int N; cin >> N; int cookie = 1, times = 0; if (N > 1 && N % 2 == 1) { N--; times++; } while (cookie * 2 <= N) { cookie *= 2; times++; } cout << times + (N - cookie > 0) << endl; }