#include <bits/stdc++.h>
using namespace std;
vector<double> tree[1000000];
int lstpar;
void update(int index, double quan) {
  if (index > lstpar) {
    if (abs(tree[index][2] - 1) < 1e-8)
      return;
    else
      tree[index][2] += quan;
    return;
  }
  if (abs(tree[index][2] - 1) < 1e-8) {
    update(tree[index][0], quan / 2);
    update(tree[index][1], quan / 2);
  } else {
    tree[index][2] += quan;
    return;
  }
}
int main() {
  int n, t;
  cin >> n >> t;
  int par = 1, son = 2;
  for (int i = 1; i < n + 2; i++) {
    for (int j = 0; j < i; j++) {
      tree[par].push_back(son);
      tree[par].push_back(son + 1);
      tree[par].push_back(0);
      son++;
      par++;
    }
    son++;
  }
  lstpar = n * (n - 1) / 2;
  while (t--) update(1, 1);
  int ans = 0;
  for (int i = 1; i < n * (n + 1) / 2 + 1; i++)
    if (abs(tree[i][2] - 1) < 1e-8) ans++;
  cout << ans;
  return 0;
}
