#include <bits/stdc++.h>
using namespace std;
char s[100010];
int main() {
  long long n, k;
  scanf("%I64d %I64d", &n, &k);
  while (n) {
    long long tmp = 1ll << (n - 1);
    if (tmp < k)
      k = (tmp << 1) - k;
    else if (tmp == k) {
      printf("%d", n);
      break;
    }
    n--;
  }
}
