#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, a, b, d, s = 0, k = 0;
  cin >> n >> b >> d;
  for (int i = 0; i < n; i++) {
    cin >> a;
    if (a <= b) s += a;
    if (s > d) {
      k++;
      s = 0;
    }
  }
  cout << k;
}
