#include <bits/stdc++.h>
using namespace std;
const int N = 3e5 + 5;
long long a[N];
int main() {
  ios_base ::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  long long n, t;
  cin >> n >> t;
  vector<long long> v;
  int x;
  int mini = INT_MAX;
  for (int i = 0; i < n; i++) cin >> x, v.push_back(x), mini = min(mini, x);
  long long ans = 0;
  while (t >= mini) {
    long long sum = 0;
    for (auto i : v) {
      sum += i;
      ans += (i <= t);
      if (i <= t) t -= i;
    }
    int nn = (int)v.size();
    long long times = t / sum;
    ans += times * nn;
    t -= times * sum;
    vector<long long> u;
    for (auto i : v)
      if (i <= t) u.push_back(i);
    swap(u, v);
  }
  cout << ans;
  return 0;
}
