#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, b, d, incremant = 0, sum = 0;
  cin >> n >> b >> d;
  int x[n];
  for (int i = 0; i < n; i++) {
    cin >> x[i];
    if (x[i] > b) {
      continue;
    } else {
      sum += x[i];
      if (sum > d) {
        ++incremant;
        sum = 0;
      }
    }
  }
  cout << incremant;
  return 0;
}
