#include <bits/stdc++.h>
using namespace std;
const long long inf = 1e18 + 88;
const int maxn = 2e5 + 88;
long long a[maxn], cur[10], cura[10];
long long curbase[10][10], base[10][10];
long long k;
int n;
int readint() {
  int cur;
  scanf("%d", &cur);
  return cur;
}
long long readll() {
  long long cur;
  scanf("%I64d", &cur);
  return cur;
}
void writell(long long x) { printf("%I64d", x); }
long long brut(long long res) {
  for (int i = 0; i < n; i++)
    if (a[i] >= k)
      return res;
    else
      a[i] = a[i] + (i ? a[i - 1] : 0);
  return brut(res + 1);
}
long long umn(long long a, long long b) {
  long long cur = a * b;
  if (b != 0 && cur / b != a) cur = k;
  return min(cur, k);
}
void summ(long long &a, long long b) { a = min(a + b, k); }
void umncurbase() {
  int i, j, k;
  for (i = 0; i < n; i++) cura[i] = 0;
  for (j = 0; j < n; j++)
    for (k = 0; k < n; k++) summ(cura[j], umn(cur[k], base[k][j]));
  for (i = 0; i < n; i++) cur[i] = cura[i];
}
void umnbasebase() {
  int i, j, k;
  for (i = 0; i < n; i++)
    for (j = 0; j < n; j++) curbase[i][j] = 0;
  for (i = 0; i < n; i++)
    for (j = 0; j < n; j++)
      for (k = 0; k < n; k++) summ(curbase[i][j], umn(base[i][k], base[k][j]));
  for (i = 0; i < n; i++)
    for (j = 0; j < n; j++) base[i][j] = curbase[i][j];
}
void binpow(long long pow) {
  if (pow == 1) {
    int i;
    i = 1;
  }
  int i, j;
  long long curpow = pow;
  for (i = 0; i < n; i++)
    for (j = 0; j < n; j++) base[i][j] = (i <= j) ? 1 : 0;
  for (i = 0; i < n; i++) cur[i] = a[i];
  while (curpow) {
    if (curpow % 2) {
      curpow--;
      umncurbase();
    } else {
      curpow /= 2;
      umnbasebase();
    }
  }
}
bool check(long long pow) {
  binpow(pow);
  for (int i = 0; i < n; i++)
    if (cur[i] == k) return true;
  return false;
}
long long bin() {
  long long l = 0, r = inf;
  while (l < r) {
    long long mid = (l + r) / 2;
    if (check(mid))
      r = mid;
    else
      l = mid + 1;
  }
  return l;
}
int main() {
  int i;
  n = readint();
  k = readll();
  for (i = 0; i < n; i++) a[i] = readint();
  int cnt0 = 0;
  while (a[cnt0] == 0) cnt0++;
  for (i = 0; i < n - cnt0; i++) a[i] = a[i + cnt0];
  n -= cnt0;
  if (n > 10)
    writell(brut(0));
  else
    writell(bin());
  return 0;
}
