#include <bits/stdc++.h>
using namespace std;
unsigned long long res(unsigned long long n, unsigned long long k) {
  unsigned long long size = pow(2, n) - 1;
  if (k == size / 2) return n;
  if (k > size / 2) return res(n, size - k - 1);
  return res(n - 1, k);
}
int main() {
  unsigned long long n, k;
  cin >> n >> k;
  k = k - 1;
  cout << res(n, k) << endl;
  return 0;
}
