#include <bits/stdc++.h>
using namespace std;
void err(istream_iterator<string> it) {}
template <typename T, typename... Args>
void err(istream_iterator<string> it, T a, Args... args) {
  cerr << *it << " = " << a << endl;
  err(++it, args...);
}
int main() {
  ios_base::sync_with_stdio(false);
  long long int n, t, mn = 1e18 + 2;
  cin >> n >> t;
  long long int a[n];
  for (int i = 0; i < n; i++) {
    cin >> a[i];
    mn = min(mn, a[i]);
  }
  long long int ans = 0;
  while (t >= mn) {
    long long int cnt = 0;
    long long int temp = t, x = 0;
    for (int i = 0; i < n; i++) {
      if (a[i] <= temp) {
        cnt++;
        temp -= a[i];
        x += a[i];
      }
    }
    if (temp >= 0) {
      ans += (t / x) * cnt;
      t = t % x;
    }
  }
  cout << ans << endl;
  return 0;
}
