#include <bits/stdc++.h>
using namespace std;
double a[11][11];
int n, t;
void pour(double x, int i, int j) {
  if (x <= 0) return;
  if (i == n) return;
  if (a[i][j] + x <= 1) {
    a[i][j] += x;
    return;
  } else {
    x -= (1.0 - a[i][j]);
    a[i][j] = 1;
  }
  pour(x / 2.0, i + 1, j);
  pour(x / 2.0, i + 1, j + 1);
}
int main() {
  ios::sync_with_stdio(0);
  ;
  cin >> n >> t;
  while (t--) {
    pour(1, 0, 0);
  }
  int res = 0;
  for (int i = 0; i < n; i++)
    for (int j = 0; j <= i; j++) res += (a[i][j] == 1);
  cout << res << endl;
  return 0;
}
