#include <bits/stdc++.h>
using namespace std;
const int N = 1e6 + 5;
const int mod = 1e9 + 7;
int32_t main() {
  long long int n, t;
  cin >> n >> t;
  long long int a[n];
  for (int i = 0; i < n; i++) cin >> a[i];
  long long int ans = 0;
  while (1) {
    long long int cur = 0, sum = 0;
    for (int i = 0; i < n; i++) {
      if (t >= a[i]) {
        t -= a[i];
        sum += a[i];
        cur++;
      }
    }
    if (!cur) break;
    ans += cur;
    ans += (t / sum) * cur;
    t %= sum;
  }
  cout << ans;
  return 0;
}
